| Dimension | Shared | Only in A | Only in B | Overlap |
|---|---|---|---|---|
| Sections | 0 | 8 | 11 | 0% |
| Commands | 0 | 1 | 0 | 0% |
| Section tags | 1 | 4 | 3 | 13% |
What each file covers
Sections
0 shared · 8 only in A · 11 only in B- − Next.js Frontend Conventions
- − App Router Structure
- − Component Organization
- − API Integration
- − Styling
- − Data Fetching
- − Internationalization
- − Testing
- + AI Memory Rule
- + Purpose
- + Storage
- + Updating Memory
- + Using Memory
- + Example Scenario
- + Memory File (`.cursor/rules/learned-memories.mdc`)
- + Project Memory
- + User Preferences
- + Technical Decisions
- + Project Conventions
Commands
0 shared · 1 only in A · 0 only in B- − cypress/fixtures/
Section tags
1 shared · 4 only in A · 3 only in B- − test
- − architecture
- − api
- − ui
- + performance
- + do-not
- + agent-behaviour
- code-style
Line diff
magdazelena/primer · .cursor/rules/nextjs-frontend.mdc
@@ −1 @@
1---
2globs: apps/frontend/**/*.tsx,apps/frontend/**/*.ts
3---
4
5# Next.js Frontend Conventions
6
7## App Router Structure
8
9Follow Next.js 14 App Router in [apps/frontend/src/app/](mdc:apps/frontend/src/app/):
10
11- **Route Groups**: Use parentheses `(auth)`, `(dashboard)`
12- **Dynamic Routes**: Use brackets `[lang]`, `[id]`
13- **Layouts**: `layout.tsx` for shared layouts
14- **Pages**: `page.tsx` for route components
15
16## Component Organization
17
18Structure components in [apps/frontend/src/components/](mdc:apps/frontend/src/components/):
19
20- **Common**: Shared UI components
21- **Forms**: Form-related components
22- **Layout**: Page layout components
23- Use PascalCase for component files
24
25## API Integration
26
27- **API Helpers**: [apps/frontend/src/api/](mdc:apps/frontend/src/api/)
28- **Types**: [apps/frontend/src/types/](mdc:apps/frontend/src/types/)
29- **Hooks**: [apps/frontend/src/hooks/](mdc:apps/frontend/src/hooks/)
30
31## Styling
32
33- **Tailwind CSS**: Utility-first approach
34- **Responsive**: Mobile-first design
35- **Theme**: Custom configuration in `tailwind.config.js`
36
37## Data Fetching
38
39- Use Server Components for initial data
40- Client Components for interactivity
41- Proper error boundaries and loading states
42- Type-safe API calls with generated types
43
44## Internationalization
45
46- Multi-language support with `[lang]` routes
47- Configuration in [apps/frontend/i18n-config.ts](mdc:apps/frontend/i18n-config.ts)
48- Middleware for language detection
49
50## Testing
51
52- **Unit Tests**: Jest with React Testing Library
53- **E2E Tests**: Cypress in [apps/frontend/cypress/](mdc:apps/frontend/cypress/)
54- **Fixtures**: Test data in `cypress/fixtures/`
magdazelena/primer · .cursor/rules/memory.mdc
@@ +1 @@
1---
2alwaysApply: true
3---
4# AI Memory Rule
5
6This rule defines how the AI should manage and utilize its "memory" regarding this specific project, including user preferences, learned facts, and project-specific conventions.
7
8## Purpose
9
10The AI's memory helps maintain consistency and adapt to specific project needs or user preferences discovered during interactions. It prevents the AI from repeatedly asking for the same information or making suggestions contrary to established patterns.
11
12## Storage
13
14All learned project-specific knowledge and preferences should be stored and referenced in the `learned-memories.mdc` file located in `.cursor/rules`.
15
16## Updating Memory
17
18When new information relevant to the project's conventions, user preferences, or specific technical details is learned (either explicitly told by the user or inferred through conversation), the AI should:
19
201. **Identify Key Information:** Determine the core piece of knowledge to be stored.
212. **Check Existing Memory:** Review `learned-memories.mdc` to see if this information contradicts or updates existing entries.
223. **Propose Update:** Suggest an edit to `learned-memories.mdc` to add or modify the relevant information. Keep entries concise and clear.
23
24## Using Memory
25
26Before proposing solutions, code changes, or answering questions, the AI should consult `learned-memories.mdc` to ensure its response aligns with the recorded knowledge and preferences.
27
28## Example Scenario
29
30**User:** "We've decided to use Tailwind v4 for this project, not v3."
31
32**AI Action:**
33
341. Recognize this as a project-specific technical decision.
352. Check `learned-memories.mdc` for existing Tailwind version information.
363. Propose adding or updating an entry in `learned-memories.mdc`:
37 ```markdown
38 ## Technical Decisions
39
40 * **CSS Framework:** Tailwind v4 is used. Ensure usage aligns with v4 documentation and practices, noting differences from v3.
41 ```
424. In subsequent interactions involving Tailwind, the AI will refer to this entry and consult v4 documentation if necessary.
43
44## Memory File (`.cursor/rules/learned-memories.mdc`)
45
46The basic structure:
47
48```markdown
49# Project Memory
50
51This file stores project-specific knowledge, conventions, and user preferences learned by the AI assistant.
52
53## User Preferences
54
55- [Preference 1]
56- [Preference 2]
57
58## Technical Decisions
59
60- [Decision 1]
61- [Decision 2]
62
63## Project Conventions
64
65- [Convention 1]
66- [Convention 2]
67```
68---
69alwaysApply: true
70---
71
@@ −1 +1 @@
11 ---
2−globs: apps/frontend/**/*.tsx,apps/frontend/**/*.ts
2+alwaysApply: true
33 ---
4+# AI Memory Rule
45
5−# Next.js Frontend Conventions
6+This rule defines how the AI should manage and utilize its "memory" regarding this specific project, including user preferences, learned facts, and project-specific conventions.
67
7−## App Router Structure
8+## Purpose
89
9−Follow Next.js 14 App Router in [apps/frontend/src/app/](mdc:apps/frontend/src/app/):
10+The AI's memory helps maintain consistency and adapt to specific project needs or user preferences discovered during interactions. It prevents the AI from repeatedly asking for the same information or making suggestions contrary to established patterns.
1011
11−- **Route Groups**: Use parentheses `(auth)`, `(dashboard)`
12−- **Dynamic Routes**: Use brackets `[lang]`, `[id]`
13−- **Layouts**: `layout.tsx` for shared layouts
14−- **Pages**: `page.tsx` for route components
12+## Storage
1513
16−## Component Organization
14+All learned project-specific knowledge and preferences should be stored and referenced in the `learned-memories.mdc` file located in `.cursor/rules`.
1715
18−Structure components in [apps/frontend/src/components/](mdc:apps/frontend/src/components/):
16+## Updating Memory
1917
20−- **Common**: Shared UI components
21−- **Forms**: Form-related components
22−- **Layout**: Page layout components
23−- Use PascalCase for component files
18+When new information relevant to the project's conventions, user preferences, or specific technical details is learned (either explicitly told by the user or inferred through conversation), the AI should:
2419
25−## API Integration
20+1. **Identify Key Information:** Determine the core piece of knowledge to be stored.
21+2. **Check Existing Memory:** Review `learned-memories.mdc` to see if this information contradicts or updates existing entries.
22+3. **Propose Update:** Suggest an edit to `learned-memories.mdc` to add or modify the relevant information. Keep entries concise and clear.
2623
27−- **API Helpers**: [apps/frontend/src/api/](mdc:apps/frontend/src/api/)
28−- **Types**: [apps/frontend/src/types/](mdc:apps/frontend/src/types/)
29−- **Hooks**: [apps/frontend/src/hooks/](mdc:apps/frontend/src/hooks/)
24+## Using Memory
3025
31−## Styling
26+Before proposing solutions, code changes, or answering questions, the AI should consult `learned-memories.mdc` to ensure its response aligns with the recorded knowledge and preferences.
3227
33−- **Tailwind CSS**: Utility-first approach
34−- **Responsive**: Mobile-first design
35−- **Theme**: Custom configuration in `tailwind.config.js`
28+## Example Scenario
3629
37−## Data Fetching
30+**User:** "We've decided to use Tailwind v4 for this project, not v3."
3831
39−- Use Server Components for initial data
40−- Client Components for interactivity
41−- Proper error boundaries and loading states
42−- Type-safe API calls with generated types
32+**AI Action:**
4333
44−## Internationalization
34+1. Recognize this as a project-specific technical decision.
35+2. Check `learned-memories.mdc` for existing Tailwind version information.
36+3. Propose adding or updating an entry in `learned-memories.mdc`:
37+ ```markdown
38+ ## Technical Decisions
4539
46−- Multi-language support with `[lang]` routes
47−- Configuration in [apps/frontend/i18n-config.ts](mdc:apps/frontend/i18n-config.ts)
48−- Middleware for language detection
40+ * **CSS Framework:** Tailwind v4 is used. Ensure usage aligns with v4 documentation and practices, noting differences from v3.
41+ ```
42+4. In subsequent interactions involving Tailwind, the AI will refer to this entry and consult v4 documentation if necessary.
4943
50−## Testing
44+## Memory File (`.cursor/rules/learned-memories.mdc`)
5145
52−- **Unit Tests**: Jest with React Testing Library
53−- **E2E Tests**: Cypress in [apps/frontend/cypress/](mdc:apps/frontend/cypress/)
54−- **Fixtures**: Test data in `cypress/fixtures/`
46+The basic structure:
47+
48+```markdown
49+# Project Memory
50+
51+This file stores project-specific knowledge, conventions, and user preferences learned by the AI assistant.
52+
53+## User Preferences
54+
55+- [Preference 1]
56+- [Preference 2]
57+
58+## Technical Decisions
59+
60+- [Decision 1]
61+- [Decision 2]
62+
63+## Project Conventions
64+
65+- [Convention 1]
66+- [Convention 2]
67+```
68+---
69+alwaysApply: true
70+---
71+
