launchframe 0.1.13 → 0.2.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (72) hide show
  1. package/README.md +143 -175
  2. package/bin/launchframe.mjs +234 -30
  3. package/package.json +52 -65
  4. package/template/.aider.conf.yml +3 -0
  5. package/template/.amazonq/cli-agents/clone-website.json +9 -0
  6. package/template/.amazonq/rules/project.md +156 -0
  7. package/template/.augment/commands/clone-website.md +516 -0
  8. package/template/.claude/skills/clone-website/SKILL.md +515 -0
  9. package/template/.clinerules +156 -0
  10. package/template/.codex/skills/clone-website/SKILL.md +515 -0
  11. package/template/.continue/commands/clone-website.md +517 -0
  12. package/template/.continue/rules/project.md +160 -0
  13. package/template/.cursor/commands/clone-website.md +512 -0
  14. package/template/.cursor/rules/project.mdc +7 -0
  15. package/template/.dockerignore +60 -0
  16. package/template/.gemini/commands/clone-website.toml +518 -0
  17. package/template/.gitattributes +9 -0
  18. package/template/.github/ISSUE_TEMPLATE/bug_report.yml +86 -0
  19. package/template/.github/ISSUE_TEMPLATE/config.yml +5 -0
  20. package/template/.github/ISSUE_TEMPLATE/feature_request.yml +50 -0
  21. package/template/.github/PULL_REQUEST_TEMPLATE.md +19 -0
  22. package/template/.github/copilot-instructions.md +156 -0
  23. package/template/.github/copilot-setup-steps.yml +3 -0
  24. package/template/.github/skills/clone-website/SKILL.md +515 -0
  25. package/template/.github/workflows/ci.yml +36 -0
  26. package/template/.nvmrc +1 -0
  27. package/template/.opencode/commands/clone-website.md +515 -0
  28. package/template/.windsurf/workflows/clone-website.md +512 -0
  29. package/template/.windsurfrules +2 -0
  30. package/template/AGENTS.md +74 -0
  31. package/template/CHANGELOG.md +80 -0
  32. package/template/CLAUDE.md +1 -0
  33. package/template/Dockerfile +114 -0
  34. package/template/Dockerfile.dev +15 -0
  35. package/template/GEMINI.md +1 -0
  36. package/template/README.md +129 -0
  37. package/template/components.json +25 -0
  38. package/template/docker-compose.yml +53 -0
  39. package/template/docs/design-references/.gitkeep +0 -0
  40. package/template/docs/design-references/comparison.png +0 -0
  41. package/template/docs/research/INSPECTION_GUIDE.md +80 -0
  42. package/template/eslint.config.mjs +18 -0
  43. package/template/next.config.ts +8 -0
  44. package/template/package.json +59 -0
  45. package/template/postcss.config.mjs +7 -0
  46. package/template/public/images/.gitkeep +0 -0
  47. package/template/public/seo/.gitkeep +0 -0
  48. package/template/public/videos/.gitkeep +0 -0
  49. package/template/scripts/.gitkeep +0 -0
  50. package/template/scripts/sync-agent-rules.sh +88 -0
  51. package/template/scripts/sync-skills.mjs +111 -0
  52. package/template/src/app/favicon.ico +0 -0
  53. package/template/src/app/globals.css +130 -0
  54. package/template/src/app/layout.tsx +33 -0
  55. package/template/src/app/page.tsx +9 -0
  56. package/template/src/components/ui/button.tsx +60 -0
  57. package/template/src/hooks/.gitkeep +0 -0
  58. package/template/src/lib/utils.ts +6 -0
  59. package/template/src/types/.gitkeep +0 -0
  60. package/template/tsconfig.json +34 -0
  61. package/packages/extract/automated-clone-pass.ts +0 -353
  62. package/packages/extract/browser-extract.ts +0 -237
  63. package/packages/extract/cloner-research-emit.ts +0 -270
  64. package/packages/extract/dom-crawler.ts +0 -521
  65. package/packages/extract/emit.ts +0 -553
  66. package/packages/extract/extract.ts +0 -547
  67. package/packages/extract/host-slug.ts +0 -5
  68. package/packages/extract/mirror-emit.ts +0 -620
  69. package/packages/extract/package.json +0 -13
  70. package/packages/extract/reference-dump.ts +0 -431
  71. package/packages/extract/synthesize.ts +0 -551
  72. package/packages/extract/types.ts +0 -316
@@ -0,0 +1,50 @@
1
+ name: Feature Request
2
+ description: Suggest a new feature or improvement
3
+ title: "[Feature]: "
4
+ labels: ["enhancement"]
5
+ body:
6
+ - type: markdown
7
+ attributes:
8
+ value: |
9
+ Thanks for suggesting a feature! Please describe the problem and your proposed solution.
10
+
11
+ - type: textarea
12
+ id: problem
13
+ attributes:
14
+ label: Problem
15
+ description: What problem does this feature solve? What's missing or frustrating?
16
+ placeholder: "I'm always frustrated when..."
17
+ validations:
18
+ required: true
19
+
20
+ - type: textarea
21
+ id: solution
22
+ attributes:
23
+ label: Proposed Solution
24
+ description: How would you like this to work?
25
+ validations:
26
+ required: true
27
+
28
+ - type: textarea
29
+ id: alternatives
30
+ attributes:
31
+ label: Alternatives Considered
32
+ description: Any other approaches you've thought about?
33
+
34
+ - type: dropdown
35
+ id: category
36
+ attributes:
37
+ label: Category
38
+ options:
39
+ - Cloning pipeline
40
+ - Asset extraction
41
+ - Component generation
42
+ - Documentation
43
+ - Developer experience
44
+ - Other
45
+
46
+ - type: textarea
47
+ id: additional
48
+ attributes:
49
+ label: Additional Context
50
+ description: Screenshots, mockups, links, or any other context.
@@ -0,0 +1,19 @@
1
+ ## Summary
2
+
3
+ <!-- What does this PR do and why? -->
4
+
5
+ ## Related Issue
6
+
7
+ <!-- Link to the issue this addresses, e.g. Closes #123 -->
8
+
9
+ ## Type of Change
10
+
11
+ - [ ] Bug fix
12
+ - [ ] New feature
13
+ - [ ] Documentation
14
+ - [ ] Refactoring
15
+ - [ ] Breaking change
16
+
17
+ ## Checklist
18
+
19
+ - [ ] `npm run check` passes (lint + typecheck + build)
@@ -0,0 +1,156 @@
1
+ <!-- AUTO-GENERATED from AGENTS.md — do not edit directly.
2
+ Run `bash scripts/sync-agent-rules.sh` to regenerate. -->
3
+
4
+ <!-- BEGIN:nextjs-agent-rules -->
5
+ # This is NOT the Next.js you know
6
+
7
+ This version has breaking changes — APIs, conventions, and file structure may all differ from your training data. Read the relevant guide in `node_modules/next/dist/docs/` before writing any code. Heed deprecation notices.
8
+ <!-- END:nextjs-agent-rules -->
9
+
10
+ # Launchframe Project (AI Website Cloner + SaaS Rebrand)
11
+
12
+ ## What This Is
13
+ This project was scaffolded by [Launchframe](https://github.com/evangruhlkey/launchframe) via `npx launchframe@latest <url> "<saas idea>"`. It is a Next.js + shadcn/ui + Tailwind v4 base wired with an AI-cloner skill (`/clone-website`) that reverse-engineers a real website pixel-perfectly and then re-skins its copy/branding for the user's SaaS idea.
14
+
15
+ ## Single Source of Truth: `launchframe.config.json`
16
+ At the project root there is a `launchframe.config.json` containing:
17
+ - `url` — the visual source-of-truth to clone
18
+ - `idea` — the SaaS idea used as the rebranding directive after the clone
19
+
20
+ **Always read this file first** at the start of any cloning or build task. The `/clone-website` skill depends on it.
21
+
22
+ ## Tech Stack
23
+ - **Framework:** Next.js 16 (App Router, React 19, TypeScript strict)
24
+ - **UI:** shadcn/ui (Radix primitives, Tailwind CSS v4, `cn()` utility)
25
+ - **Icons:** Lucide React (default — will be replaced/supplemented by extracted SVGs)
26
+ - **Styling:** Tailwind CSS v4 with oklch design tokens
27
+ - **Deployment:** Vercel
28
+
29
+ ## Commands
30
+ - `npm run dev` — Start dev server
31
+ - `npm run build` — Production build
32
+ - `npm run lint` — ESLint check
33
+ - `npm run typecheck` — TypeScript check
34
+ - `npm run check` — Run lint + typecheck + build
35
+
36
+ ## Code Style
37
+ - TypeScript strict mode, no `any`
38
+ - Named exports, PascalCase components, camelCase utils
39
+ - Tailwind utility classes, no inline styles
40
+ - 2-space indentation
41
+ - Responsive: mobile-first
42
+
43
+ ## Design Principles
44
+ - **Pixel-perfect emulation** — match the target's spacing, colors, typography exactly
45
+ - **No personal aesthetic changes during emulation phase** — match 1:1 first, rebrand later
46
+ - **Real content during extraction** — use actual text and assets from the target site so the clone scaffolds against real shapes
47
+ - **Rebrand pass swaps copy, not visuals** — once the clone is built, replace product name, headlines, feature copy, and brand marks with content tuned to `launchframe.config.json#idea`. Do NOT alter spacing, color tokens, typography scale, animations, or responsive breakpoints during the rebrand.
48
+ - **Beauty-first** — every pixel matters
49
+
50
+ ## Project Structure
51
+ ```
52
+ src/
53
+ app/ # Next.js routes
54
+ components/ # React components
55
+ ui/ # shadcn/ui primitives
56
+ icons.tsx # Extracted SVG icons as React components
57
+ lib/
58
+ utils.ts # cn() utility (shadcn)
59
+ types/ # TypeScript interfaces
60
+ hooks/ # Custom React hooks
61
+ public/
62
+ images/ # Downloaded images from target site
63
+ videos/ # Downloaded videos from target site
64
+ seo/ # Favicons, OG images, webmanifest
65
+ docs/
66
+ research/ # Inspection output (design tokens, components, layout)
67
+ design-references/ # Screenshots and visual references
68
+ scripts/ # Asset download scripts
69
+ ```
70
+
71
+ ## MOST IMPORTANT NOTES
72
+ - **Always start by reading `launchframe.config.json`** — that file dictates the URL to clone and the SaaS idea to re-skin for.
73
+ - When launching Claude Code agent teams, ALWAYS have each teammate work in their own worktree branch and merge everyone's work at the end, resolving any merge conflicts smartly since you are basically serving the orchestrator role and have full context to our goals, work given, work achieved, and desired outcomes.
74
+ - After editing `AGENTS.md`, run `bash scripts/sync-agent-rules.sh` to regenerate platform-specific instruction files.
75
+ - After editing `.claude/skills/clone-website/SKILL.md`, run `node scripts/sync-skills.mjs` to regenerate the skill for all platforms.
76
+
77
+ # Website Inspection Guide
78
+
79
+ ## How to Reverse-Engineer Any Website
80
+
81
+ This guide outlines what to capture when inspecting a target website via Chrome MCP or browser DevTools.
82
+
83
+ ## Phase 1: Visual Audit
84
+
85
+ ### Screenshots to Capture
86
+ - [ ] Every distinct page — desktop, tablet, mobile
87
+ - [ ] Dark mode variants (if applicable)
88
+ - [ ] Light mode variants (if applicable)
89
+ - [ ] Key interaction states (hover, active, open menus, modals)
90
+ - [ ] Loading/skeleton states
91
+ - [ ] Empty states
92
+ - [ ] Error states
93
+
94
+ ### Design Tokens to Extract
95
+ - [ ] **Colors** — background, text (primary/secondary/muted), accent, border, hover, error, success, warning
96
+ - [ ] **Typography** — font family, sizes (h1-h6, body, caption, label), weights, line heights, letter spacing
97
+ - [ ] **Spacing** — padding/margin patterns (look for a scale: 4px, 8px, 12px, 16px, 24px, 32px, etc.)
98
+ - [ ] **Border radius** — buttons, cards, avatars, inputs
99
+ - [ ] **Shadows/elevation** — card shadows, dropdown shadows, modal overlay
100
+ - [ ] **Breakpoints** — when does the layout shift? (inspect with DevTools responsive mode)
101
+ - [ ] **Icons** — which icon library? custom SVGs? sizes?
102
+ - [ ] **Avatars** — sizes, shapes, fallback behavior
103
+ - [ ] **Buttons** — all variants (primary, secondary, ghost, icon-only, danger)
104
+ - [ ] **Inputs** — text fields, textareas, selects, checkboxes, toggles
105
+
106
+ ## Phase 2: Component Inventory
107
+
108
+ For each distinct UI component, document:
109
+ 1. **Name** — what would you call this component?
110
+ 2. **Structure** — what HTML elements / child components does it contain?
111
+ 3. **Variants** — does it have different sizes, colors, or states?
112
+ 4. **States** — default, hover, active, disabled, loading, error, empty
113
+ 5. **Responsive behavior** — how does it change at different breakpoints?
114
+ 6. **Interactions** — click, hover, focus, keyboard navigation
115
+ 7. **Animations** — transitions, entrance/exit animations, micro-interactions
116
+
117
+ ### Common Components to Look For
118
+ - Navigation (top bar, sidebar, bottom bar)
119
+ - Cards / list items
120
+ - Buttons and links
121
+ - Forms and inputs
122
+ - Modals and dialogs
123
+ - Dropdowns and menus
124
+ - Tabs and segmented controls
125
+ - Avatars and user badges
126
+ - Loading skeletons
127
+ - Toast notifications
128
+ - Tooltips and popovers
129
+
130
+ ## Phase 3: Layout Architecture
131
+
132
+ - [ ] **Grid system** — CSS Grid? Flexbox? Fixed widths?
133
+ - [ ] **Column layout** — how many columns at each breakpoint?
134
+ - [ ] **Max-width** — main content area max-width
135
+ - [ ] **Sticky elements** — header, sidebar, floating buttons
136
+ - [ ] **Z-index layers** — navigation, modals, tooltips, overlays
137
+ - [ ] **Scroll behavior** — infinite scroll, pagination, virtual scrolling
138
+
139
+ ## Phase 4: Technical Stack Analysis
140
+
141
+ - [ ] **Framework** — React? Vue? Angular? Check `__NEXT_DATA__`, `__NUXT__`, `ng-version`
142
+ - [ ] **CSS approach** — Tailwind (utility classes), CSS Modules, Styled Components, Emotion, vanilla CSS
143
+ - [ ] **State management** — Redux (check DevTools), React Query, Zustand, Pinia
144
+ - [ ] **API patterns** — REST, GraphQL (check network tab for `/graphql` requests)
145
+ - [ ] **Font loading** — Google Fonts, self-hosted, system fonts
146
+ - [ ] **Image strategy** — CDN, lazy loading, srcset, WebP/AVIF
147
+ - [ ] **Animation library** — Framer Motion, GSAP, CSS transitions only
148
+
149
+ ## Phase 5: Documentation Output
150
+
151
+ After inspection, create these files in `docs/research/`:
152
+ 1. `DESIGN_TOKENS.md` — All extracted colors, typography, spacing
153
+ 2. `COMPONENT_INVENTORY.md` — Every component with structure notes
154
+ 3. `LAYOUT_ARCHITECTURE.md` — Page layouts, grid system, responsive behavior
155
+ 4. `INTERACTION_PATTERNS.md` — Animations, transitions, hover states
156
+ 5. `TECH_STACK_ANALYSIS.md` — What the site uses and our chosen equivalents
@@ -0,0 +1,3 @@
1
+ steps:
2
+ - name: Install dependencies
3
+ run: npm ci