launchframe 0.4.8 → 0.4.10

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.
@@ -2,89 +2,128 @@
2
2
 
3
3
  ## How to Reverse-Engineer Any Website
4
4
 
5
- This guide outlines what to capture when inspecting a target website via Chrome MCP or browser DevTools.
5
+ This guide is the **canonical workflow** when inspecting a target site (Chrome MCP, DevTools, or similar). Execute the steps **in order**: structure and styles establish the blueprint; motion and assets define feel and legality; implementation is always a deliberate rebuild—not a pasted dump.
6
6
 
7
- ## Priority: media, SVGs, and motion (do this early)
7
+ ---
8
8
 
9
- When crawling the DOM and network, **tackle these before fine-tuning copy or spacing**:
9
+ ## Step 1 Structure (DOM hierarchy only)
10
10
 
11
- 1. **Raster imagery** — Every `<img>`, `<picture>` / `source`, `srcset` / `sizes`, CDN URLs, lazy-loaded `data-src`, `loading="lazy"` nodes, **CSS `background-image`** on the element and ancestors (including `::before` / `::after`), masks that use `url()`, `<video>` still / poster frames. Prefer **downloading** originals via scripts or MCP; if a URL is blocked or session-gated, **export a screenshot** of the element’s bounding box at a crisp DPR and store it under `public/images/`, and note the substitute in the spec.
12
- 2. **SVGs** — Inline `<svg>`, `<use>` / sprite sheets, **SVG in CSS** (`mask-image`, `background-image`), favicons as SVG, logo marks. Prefer extracting path/viewBox into React components or static files under `public/` — **recreate** from a screenshot/trace only when the markup is obfuscated or blocked.
13
- 3. **Motion & animation** — Inspect Styles for `animation`, `animation-name`, `animation-timeline`, `transition`, `transform`, `@keyframes`; check for libraries (Framer Motion, GSAP, Lottie, Lenis). Capture **durations, easings, delays, fill-modes**, scroll/view triggers, and `prefers-reduced-motion` handling. Motion often defines perceived quality — do not leave it as an afterthought.
11
+ Treat HTML as a **map of hierarchy**, not as shippable source code.
14
12
 
15
- Then continue with typography, spacing, and component structure as usual.
13
+ - **DevTools limitation:** Copying `<head>` and `<body>` with “Copy Copy outerHTML” gives **one frozen snapshot**. It omits most **stylesheet and script** behavior and may inline classes whose meaning lives in external bundles.
14
+ - **What to extract anyway:** Landmark regions, heading levels, nesting (sections → rows → cards), repeated patterns, form fields, navigation trees, semantic roles.
15
+ - **What not to do:** Do not paste a single giant HTML file into production or assume it reproduces routing, hydration, or data fetching.
16
16
 
17
- ## Phase 1: Visual Audit
17
+ ### Component & layout checklist (supports Step 1)
18
+
19
+ **Component inventory** — For each distinct UI block, capture:
18
20
 
19
- ### Screenshots to Capture
20
- - [ ] Every distinct page — desktop, tablet, mobile
21
- - [ ] Dark mode variants (if applicable)
22
- - [ ] Light mode variants (if applicable)
23
- - [ ] Key interaction states (hover, active, open menus, modals)
24
- - [ ] Loading/skeleton states
25
- - [ ] Empty states
26
- - [ ] Error states
27
-
28
- ### Design Tokens to Extract
29
- - [ ] **Colors** — background, text (primary/secondary/muted), accent, border, hover, error, success, warning
30
- - [ ] **Typography** — font family, sizes (h1-h6, body, caption, label), weights, line heights, letter spacing
31
- - [ ] **Spacing** — padding/margin patterns (look for a scale: 4px, 8px, 12px, 16px, 24px, 32px, etc.)
32
- - [ ] **Border radius** — buttons, cards, avatars, inputs
33
- - [ ] **Shadows/elevation** — card shadows, dropdown shadows, modal overlay
34
- - [ ] **Breakpoints** — when does the layout shift? (inspect with DevTools responsive mode)
35
- - [ ] **Icons** — which icon library? custom SVGs? sizes?
36
- - [ ] **Avatars** — sizes, shapes, fallback behavior
37
- - [ ] **Buttons** — all variants (primary, secondary, ghost, icon-only, danger)
38
- - [ ] **Inputs** — text fields, textareas, selects, checkboxes, toggles
39
-
40
- ## Phase 2: Component Inventory
41
-
42
- For each distinct UI component, document:
43
21
  1. **Name** — what would you call this component?
44
- 2. **Structure** — what HTML elements / child components does it contain?
45
- 3. **Variants** — does it have different sizes, colors, or states?
22
+ 2. **Structure** — HTML elements / child components and order
23
+ 3. **Variants** — sizes, tones, densities
46
24
  4. **States** — default, hover, active, disabled, loading, error, empty
47
- 5. **Responsive behavior** — how does it change at different breakpoints?
48
- 6. **Interactions** — click, hover, focus, keyboard navigation
49
- 7. **Animations** — transitions, entrance/exit animations, micro-interactions
50
-
51
- ### Common Components to Look For
52
- - Navigation (top bar, sidebar, bottom bar)
53
- - Cards / list items
54
- - Buttons and links
55
- - Forms and inputs
56
- - Modals and dialogs
57
- - Dropdowns and menus
58
- - Tabs and segmented controls
59
- - Avatars and user badges
60
- - Loading skeletons
61
- - Toast notifications
62
- - Tooltips and popovers
63
-
64
- ## Phase 3: Layout Architecture
65
-
66
- - [ ] **Grid system** — CSS Grid? Flexbox? Fixed widths?
67
- - [ ] **Column layout** — how many columns at each breakpoint?
68
- - [ ] **Max-width** main content area max-width
69
- - [ ] **Sticky elements** — header, sidebar, floating buttons
70
- - [ ] **Z-index layers** navigation, modals, tooltips, overlays
71
- - [ ] **Scroll behavior** — infinite scroll, pagination, virtual scrolling
72
-
73
- ## Phase 4: Technical Stack Analysis
74
-
75
- - [ ] **Framework** — React? Vue? Angular? Check `__NEXT_DATA__`, `__NUXT__`, `ng-version`
76
- - [ ] **CSS approach** — Tailwind (utility classes), CSS Modules, Styled Components, Emotion, vanilla CSS
77
- - [ ] **State management** — Redux (check DevTools), React Query, Zustand, Pinia
78
- - [ ] **API patterns** — REST, GraphQL (check network tab for `/graphql` requests)
79
- - [ ] **Font loading** — Google Fonts, self-hosted, system fonts
80
- - [ ] **Image strategy** — CDN, lazy loading, srcset, WebP/AVIF
81
- - [ ] **Animation library** — Framer Motion, GSAP, CSS transitions only
82
-
83
- ## Phase 5: Documentation Output
84
-
85
- After inspection, create these files in `docs/research/`:
86
- 1. `DESIGN_TOKENS.md` All extracted colors, typography, spacing
87
- 2. `COMPONENT_INVENTORY.md`Every component with structure notes
88
- 3. `LAYOUT_ARCHITECTURE.md` — Page layouts, grid system, responsive behavior
89
- 4. `INTERACTION_PATTERNS.md` — Animations, transitions, hover states
90
- 5. `TECH_STACK_ANALYSIS.md` — What the site uses and our chosen equivalents
25
+ 5. **Responsive behavior** — changes per breakpoint
26
+ 6. **Interactions** — click, hover, focus, keyboard
27
+
28
+ **Layout architecture**
29
+
30
+ - [ ] **Grid vs flex** — primary layout mechanism
31
+ - [ ] **Columns** — count per breakpoint
32
+ - [ ] **Max-width** — content well width
33
+ - [ ] **Sticky / fixed** — header, sidebars, floating CTAs
34
+ - [ ] **Z-index layers** — nav, overlays, tooltips
35
+ - [ ] **Scroll model** — normal, infinite, virtual lists, snap
36
+
37
+ **Screenshots** (tie each shot to a section in the hierarchy)
38
+
39
+ - [ ] Every distinct page — desktop, tablet, mobile
40
+ - [ ] Theme variants (light / dark if applicable)
41
+ - [ ] Hover, active, menus open, modals
42
+ - [ ] Loading / skeleton / empty / error states
43
+
44
+ ---
45
+
46
+ ## Step 2Styles (computed appearance + real CSS)
47
+
48
+ Rendered look comes from **CSS** (linked files, injected `<style>` blocks, build output)—not from raw element copy alone.
49
+
50
+ - **Per-element:** In DevTools **Styles** / **Computed**, capture what matters for fidelity: typography, spacing, colors, borders, shadows, breakpoints where rules change.
51
+ - **Global:** From **Sources** or **Network**, identify main stylesheets / CSS chunks; note filenames or URLs for the agents or scripts that will mirror tokens.
52
+ - **Design tokens to extract**
53
+
54
+ - [ ] **Colors** — background, text (primary / secondary / muted), accent, border, hover / focus, semantic (error, success, warning)
55
+ - [ ] **Typography** — families, scale (h1–h6, body, captions), weights, line-height, letter-spacing
56
+ - [ ] **Spacing** — padding/margin rhythm (e.g. 4/8/12/16…)
57
+ - [ ] **Radius & elevation** — cards, buttons, inputs, overlays
58
+ - [ ] **Breakpoints** — layout shifts (responsive mode)
59
+ - [ ] **Icons & avatars** — sizes, masks, fallbacks
60
+
61
+ **Technical CSS context** (informs Tailwind mapping)
62
+
63
+ - [ ] **CSS approach** utilities vs modules vs styled components vs vanilla
64
+ - [ ] **Fonts** Google, self-hosted, system stacks
65
+ - [ ] **Image CSS** `object-fit`, `aspect-ratio`, background layers
66
+
67
+ ---
68
+
69
+ ## Step 3 — Motion (what moves and how)
70
+
71
+ Motion is rarely recoverable from HTML copy; it lives in **CSS animations/transitions** and often **JavaScript** (scroll, gestures, carousel timing).
72
+
73
+ - **Catalog behaviors:** Entrance, hover, focus, drag, scroll-linked, carousel stagger, modal open/close, page transitions.
74
+ - **From Styles / Sources:** `animation-*`, `@keyframes`, `transition`, `transform`, `will-change`; note **duration, easing, delay, fill-mode**.
75
+ - **Libraries:** Identify Framer Motion, GSAP, Lottie, Lenis, CSS-only, etc.
76
+ - **Accessibility:** Note `prefers-reduced-motion` behavior if present.
77
+
78
+ **Priority reminder:** Capture **motion early** alongside media—perceived polish depends on it; do not leave it until the end.
79
+
80
+ ---
81
+
82
+ ## Step 4 — Assets (permission-neutral bytes + originals where required)
83
+
84
+ **Early capture**
85
+
86
+ 1. **Raster imagery** — `<img>`, `<picture>` / `<source>`, `srcset` / `sizes`, CDN URLs, lazy `data-src`, `loading="lazy"`, **`background-image`** on elements and ancestors (including `::before` / `::after`), masks using `url()`, video posters / stills.
87
+ 2. **SVGs** — Inline `<svg>`, `<use>` / sprites, **SVG in CSS** (`mask-image`, backgrounds), favicons. Prefer extracting path/viewBox into React components or files under `public/` — recreate from screenshot/trace only when markup is blocked or obfuscated.
88
+ 3. **Brand-safe slots** — **Marketing photos and illustrative hero/feature art** must not be photocopied when policy requires originality: ship **committed** files under `public/images/` (etc.), generated for **your** product idea; document paths in `docs/research/LAUNCHFRAME.md`. Blank placeholders are unfinished.
89
+ 4. **Fallbacks** — If URLs are gated, export a crisp screenshot of the element’s box (note DPR) and record the substitution in research notes.
90
+
91
+ **Technical**
92
+
93
+ - [ ] CDN vs origin paths
94
+ - [ ] Lazy loading and responsive image strategy
95
+
96
+ ---
97
+
98
+ ## Step 5 — Implementation (Next.js + components)
99
+
100
+ Rebuild deliberately in **this template’s stack** (Next.js App Router, React, TypeScript strict, shadcn/ui, Tailwind v4).
101
+
102
+ - **Do:** Small composable components, shared tokens, `cn()`, extracted icons in `src/components/icons.tsx` (or adjacent), routes under `src/app/`.
103
+ - **Don’t:** Ship one monolithic HTML string as the app or skip TypeScript/component boundaries.
104
+
105
+ ### Stack parity (helps choose libraries)
106
+
107
+ - [ ] **Framework signals** — e.g. `__NEXT_DATA__`, `__NUXT__`, `ng-version`
108
+ - [ ] **State / data** — REST, GraphQL, client stores (infer from Network)
109
+ - [ ] **Animation stack** — match or approximate with CSS or an approved motion library
110
+
111
+ ### Documentation output (`docs/research/`)
112
+
113
+ After inspection, produce durable notes:
114
+
115
+ 1. `DESIGN_TOKENS.md` — colors, typography, spacing, radius, shadows
116
+ 2. `COMPONENT_INVENTORY.md` — components with structure and states
117
+ 3. `LAYOUT_ARCHITECTURE.md` — grids, breakpoints, sticky layers
118
+ 4. `INTERACTION_PATTERNS.md` — motion, transitions, hover/focus
119
+ 5. `TECH_STACK_ANALYSIS.md` — source stack vs chosen equivalents
120
+
121
+ ### Common components to hunt for
122
+
123
+ Navigation (top/side/bottom), cards, buttons, links, forms, modals, menus, tabs, avatars/badges, skeletons, toasts, tooltips/popovers.
124
+
125
+ ---
126
+
127
+ ## Reference: Chrome MCP / agent crawl habits
128
+
129
+ Walk the DOM and network **top-down**. When multiple agents collaborate, reconcile tokens and animation specs in shared research files so Step 5 does not drift. For **`/launchframe`**, tie findings to `launchframe.context.json` and `docs/research/LAUNCHFRAME.md` per project conventions.
@@ -0,0 +1,73 @@
1
+ # Launchframe — subagent verification prompts
2
+
3
+ **How to use this file:** Before Phase 6, the foreman **fills or refreshes** the four prompt blocks below (they must stay **self-contained** so a subagent never needs to open the skill file). Then either:
4
+
5
+ - Spawn **four parallel** readonly agents (`Task` / team subagents / Claude Code checkers in separate worktrees), each given **one** `## Prompt — Pass N` section only, **or**
6
+ - Run the same four prompts **yourself** in order if the host has no subagents.
7
+
8
+ Each executor appends results to **`docs/research/LAUNCHFRAME_VERIFICATION.md`** using the **output contract** at the bottom.
9
+
10
+ ---
11
+
12
+ ## Prompt — Pass 1 — Raster media & icons
13
+
14
+ You are a **readonly verification subagent** for a Next.js clone. Repository root is this project.
15
+
16
+ **Rubric — execute fully:**
17
+
18
+ 1. **Narrative slots:** Inventory every reference marketing/lifestyle/card/hero **image role** described in `docs/research/` specs vs **committed files** under `public/` (e.g. `public/images/...`) actually referenced from `src/`. **FAIL** if the reference showed a photo/panel thumbnail and this clone relies on placeholders, empty `src`, or bare gradients only.
19
+ 2. List every **raster** and **video poster** and every **authored SVG / component used as an icon** referenced from `src/` (`app/`, `components/`). Confirm files exist and paths resolve.
20
+ 3. Compare presentation to specs: `picture` / `source` behavior, `sizes` / responsive behavior, `object-fit` / `object-position`, dimensions / aspect-ratio, parent overflow and radius, `background-image` and pseudo-elements.
21
+ 4. For SVGs/icons: `viewBox`, strokes, fills, `currentColor`, sprite usage must match specs — flag opportunistic Lucide substitutions unless the spec explicitly allowed them. Flag wrong crops, missing layers, or lazy `next/image` `fill` misuse.
22
+
23
+ Return the **output contract** below.
24
+
25
+ ---
26
+
27
+ ## Prompt — Pass 2 — HTML / DOM structure
28
+
29
+ You are a **readonly verification subagent** for a Next.js clone.
30
+
31
+ **Rubric — execute fully:**
32
+
33
+ Diff **PAGE_TOPOLOGY.md** (or equivalent topology in `docs/research/`) plus component specs against the React tree: **section order**, **wrapper count**, **sibling order**, scroll/sticky containers. Any flattened structure that changes stacking or scroll is **FAIL** until fixed.
34
+
35
+ Return the **output contract** below.
36
+
37
+ ---
38
+
39
+ ## Prompt — Pass 3 — CSS parity
40
+
41
+ You are a **readonly verification subagent** for a Next.js clone.
42
+
43
+ **Rubric — execute fully:**
44
+
45
+ Spot-check **hero, nav, first fold, footer** (and any section flagged risky in specs) against component CSS: tokens in `src/app/globals.css`, arbitrary Tailwind vs measured px from specs, **`@keyframes`** presence where required. Run **`npm run lint`** and **`npm run typecheck`**; failures = **FAIL** until green.
46
+
47
+ Return the **output contract** below.
48
+
49
+ ---
50
+
51
+ ## Prompt — Pass 4 — Motion & interaction
52
+
53
+ You are a **readonly verification subagent** for a Next.js clone.
54
+
55
+ **Rubric — execute fully:**
56
+
57
+ Re-walk **`docs/research/BEHAVIORS.md`** and the motion audit JSON under `## Motion audit (Chrome MCP)`: headers, carousels, scroll-driven UI, smooth-scroll libraries. Phase 5 motion QA must be **confirmed** against the reference behavior described in research — not assumed.
58
+
59
+ Return the **output contract** below.
60
+
61
+ ---
62
+
63
+ ## Output contract (every pass)
64
+
65
+ Append to **`docs/research/LAUNCHFRAME_VERIFICATION.md`**:
66
+
67
+ ```markdown
68
+ ### Pass N — <short name>
69
+ - Findings: (bullets with `path:line` where possible)
70
+ - VERDICT: PASS | FAIL
71
+ ```
72
+
73
+ If the file does not exist, create it with a top heading `# Launchframe verification log`.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "launchframe",
3
- "version": "0.4.8",
3
+ "version": "0.4.10",
4
4
  "private": false,
5
5
  "description": "Scaffold a Next.js app from a reference URL plus your SaaS idea — AI-ready website cloning",
6
6
  "author": "JCodesMore",
@@ -1,88 +1,88 @@
1
- #!/usr/bin/env bash
2
- #
3
- # sync-agent-rules.sh — Generate AI agent config files from AGENTS.md
4
- #
5
- # AGENTS.md is the single source of truth. This script creates copies
6
- # for agents that don't read AGENTS.md natively (Cline, Continue,
7
- # Amazon Q, GitHub Copilot Chat).
8
- #
9
- # Usage:
10
- # bash scripts/sync-agent-rules.sh
11
- #
12
- # Agents that DON'T need generated files (they read AGENTS.md natively):
13
- # Codex CLI, OpenCode, Cursor, Windsurf, Copilot Coding Agent,
14
- # Roo Code, Aider, Augment Code
15
- #
16
- # Agents with their own thin pointer files (created manually):
17
- # Claude Code → CLAUDE.md (@AGENTS.md import)
18
- # Gemini CLI → GEMINI.md (@AGENTS.md import)
19
- # Cursor → .cursor/rules/project.mdc (pointer)
20
- # Windsurf → .windsurfrules (pointer)
21
- # Aider → .aider.conf.yml (read: [AGENTS.md])
22
-
23
- set -euo pipefail
24
-
25
- REPO_ROOT="$(cd "$(dirname "$0")/.." && pwd)"
26
- SOURCE="$REPO_ROOT/AGENTS.md"
27
-
28
- if [[ ! -f "$SOURCE" ]]; then
29
- echo "Error: AGENTS.md not found at $SOURCE" >&2
30
- exit 1
31
- fi
32
-
33
- # Resolve @file imports (Claude Code syntax) into inline content.
34
- # Lines like "@docs/research/INSPECTION_GUIDE.md" become the file's contents.
35
- resolve_imports() {
36
- while IFS= read -r line || [[ -n "$line" ]]; do
37
- line="${line%$'\r'}"
38
- if [[ "$line" =~ ^@(.+)$ ]]; then
39
- local import_path="${BASH_REMATCH[1]}"
40
- local resolved="$REPO_ROOT/$import_path"
41
- if [[ -f "$resolved" ]]; then
42
- cat "$resolved"
43
- echo ""
44
- else
45
- echo "<!-- Import not found: $import_path -->"
46
- fi
47
- else
48
- echo "$line"
49
- fi
50
- done < "$SOURCE"
51
- }
52
-
53
- RESOLVED_CONTENT="$(resolve_imports)"
54
-
55
- HEADER="<!-- AUTO-GENERATED from AGENTS.md — do not edit directly.
56
- Run \`bash scripts/sync-agent-rules.sh\` to regenerate. -->"
57
-
58
- # Helper: write a generated file with header
59
- write_file() {
60
- local target="$1"
61
- local content="$2"
62
- mkdir -p "$(dirname "$target")"
63
- printf '%s\n\n%s\n' "$HEADER" "$content" > "$target"
64
- echo " ✓ $target"
65
- }
66
-
67
- echo "Syncing agent rules from AGENTS.md..."
68
-
69
- # GitHub Copilot Chat — .github/copilot-instructions.md
70
- write_file "$REPO_ROOT/.github/copilot-instructions.md" "$RESOLVED_CONTENT"
71
-
72
- # Cline / Roo Code — .clinerules
73
- write_file "$REPO_ROOT/.clinerules" "$RESOLVED_CONTENT"
74
-
75
- # Continue — .continue/rules/project.md
76
- CONTINUE_FRONTMATTER="---
77
- description: Project conventions for AI Website Clone Template
78
- alwaysApply: true
79
- ---"
80
- write_file "$REPO_ROOT/.continue/rules/project.md" "$CONTINUE_FRONTMATTER
81
- $RESOLVED_CONTENT"
82
-
83
- # Amazon Q Developer — .amazonq/rules/project.md
84
- write_file "$REPO_ROOT/.amazonq/rules/project.md" "$RESOLVED_CONTENT"
85
-
86
- echo ""
87
- echo "Done. Generated files are committed to the repo but sourced from AGENTS.md."
88
- echo "Edit AGENTS.md, then re-run this script to update all agent configs."
1
+ #!/usr/bin/env bash
2
+ #
3
+ # sync-agent-rules.sh — Generate AI agent config files from AGENTS.md
4
+ #
5
+ # AGENTS.md is the single source of truth. This script creates copies
6
+ # for agents that don't read AGENTS.md natively (Cline, Continue,
7
+ # Amazon Q, GitHub Copilot Chat).
8
+ #
9
+ # Usage:
10
+ # bash scripts/sync-agent-rules.sh
11
+ #
12
+ # Agents that DON'T need generated files (they read AGENTS.md natively):
13
+ # Codex CLI, OpenCode, Cursor, Windsurf, Copilot Coding Agent,
14
+ # Roo Code, Aider, Augment Code
15
+ #
16
+ # Agents with their own thin pointer files (created manually):
17
+ # Claude Code → CLAUDE.md (@AGENTS.md import)
18
+ # Gemini CLI → GEMINI.md (@AGENTS.md import)
19
+ # Cursor → .cursor/rules/project.mdc (pointer)
20
+ # Windsurf → .windsurfrules (pointer)
21
+ # Aider → .aider.conf.yml (read: [AGENTS.md])
22
+
23
+ set -euo pipefail
24
+
25
+ REPO_ROOT="$(cd "$(dirname "$0")/.." && pwd)"
26
+ SOURCE="$REPO_ROOT/AGENTS.md"
27
+
28
+ if [[ ! -f "$SOURCE" ]]; then
29
+ echo "Error: AGENTS.md not found at $SOURCE" >&2
30
+ exit 1
31
+ fi
32
+
33
+ # Resolve @file imports (Claude Code syntax) into inline content.
34
+ # Lines like "@docs/research/INSPECTION_GUIDE.md" become the file's contents.
35
+ resolve_imports() {
36
+ while IFS= read -r line || [[ -n "$line" ]]; do
37
+ line="${line%$'\r'}"
38
+ if [[ "$line" =~ ^@(.+)$ ]]; then
39
+ local import_path="${BASH_REMATCH[1]}"
40
+ local resolved="$REPO_ROOT/$import_path"
41
+ if [[ -f "$resolved" ]]; then
42
+ cat "$resolved"
43
+ echo ""
44
+ else
45
+ echo "<!-- Import not found: $import_path -->"
46
+ fi
47
+ else
48
+ echo "$line"
49
+ fi
50
+ done < "$SOURCE"
51
+ }
52
+
53
+ RESOLVED_CONTENT="$(resolve_imports)"
54
+
55
+ HEADER="<!-- AUTO-GENERATED from AGENTS.md — do not edit directly.
56
+ Run \`bash scripts/sync-agent-rules.sh\` to regenerate. -->"
57
+
58
+ # Helper: write a generated file with header
59
+ write_file() {
60
+ local target="$1"
61
+ local content="$2"
62
+ mkdir -p "$(dirname "$target")"
63
+ printf '%s\n\n%s\n' "$HEADER" "$content" > "$target"
64
+ echo " ✓ $target"
65
+ }
66
+
67
+ echo "Syncing agent rules from AGENTS.md..."
68
+
69
+ # GitHub Copilot Chat — .github/copilot-instructions.md
70
+ write_file "$REPO_ROOT/.github/copilot-instructions.md" "$RESOLVED_CONTENT"
71
+
72
+ # Cline / Roo Code — .clinerules
73
+ write_file "$REPO_ROOT/.clinerules" "$RESOLVED_CONTENT"
74
+
75
+ # Continue — .continue/rules/project.md
76
+ CONTINUE_FRONTMATTER="---
77
+ description: Project conventions for AI Website Clone Template
78
+ alwaysApply: true
79
+ ---"
80
+ write_file "$REPO_ROOT/.continue/rules/project.md" "$CONTINUE_FRONTMATTER
81
+ $RESOLVED_CONTENT"
82
+
83
+ # Amazon Q Developer — .amazonq/rules/project.md
84
+ write_file "$REPO_ROOT/.amazonq/rules/project.md" "$RESOLVED_CONTENT"
85
+
86
+ echo ""
87
+ echo "Done. Generated files are committed to the repo but sourced from AGENTS.md."
88
+ echo "Edit AGENTS.md, then re-run this script to update all agent configs."
package/tsconfig.json CHANGED
@@ -1,34 +1,34 @@
1
- {
2
- "compilerOptions": {
3
- "target": "ES2017",
4
- "lib": ["dom", "dom.iterable", "esnext"],
5
- "allowJs": true,
6
- "skipLibCheck": true,
7
- "strict": true,
8
- "noEmit": true,
9
- "esModuleInterop": true,
10
- "module": "esnext",
11
- "moduleResolution": "bundler",
12
- "resolveJsonModule": true,
13
- "isolatedModules": true,
14
- "jsx": "react-jsx",
15
- "incremental": true,
16
- "plugins": [
17
- {
18
- "name": "next"
19
- }
20
- ],
21
- "paths": {
22
- "@/*": ["./src/*"]
23
- }
24
- },
25
- "include": [
26
- "next-env.d.ts",
27
- "**/*.ts",
28
- "**/*.tsx",
29
- ".next/types/**/*.ts",
30
- ".next/dev/types/**/*.ts",
31
- "**/*.mts"
32
- ],
33
- "exclude": ["node_modules"]
34
- }
1
+ {
2
+ "compilerOptions": {
3
+ "target": "ES2017",
4
+ "lib": ["dom", "dom.iterable", "esnext"],
5
+ "allowJs": true,
6
+ "skipLibCheck": true,
7
+ "strict": true,
8
+ "noEmit": true,
9
+ "esModuleInterop": true,
10
+ "module": "esnext",
11
+ "moduleResolution": "bundler",
12
+ "resolveJsonModule": true,
13
+ "isolatedModules": true,
14
+ "jsx": "react-jsx",
15
+ "incremental": true,
16
+ "plugins": [
17
+ {
18
+ "name": "next"
19
+ }
20
+ ],
21
+ "paths": {
22
+ "@/*": ["./src/*"]
23
+ }
24
+ },
25
+ "include": [
26
+ "next-env.d.ts",
27
+ "**/*.ts",
28
+ "**/*.tsx",
29
+ ".next/types/**/*.ts",
30
+ ".next/dev/types/**/*.ts",
31
+ "**/*.mts"
32
+ ],
33
+ "exclude": ["node_modules"]
34
+ }