File tree Expand file tree Collapse file tree 1 file changed +27
-0
lines changed Expand file tree Collapse file tree 1 file changed +27
-0
lines changed Original file line number Diff line number Diff line change
1
+ Vue 3 Composition API best practices:
2
+ 1. Use setup() function for component logic
3
+ 2. Utilize ref and reactive for reactive state
4
+ 3. Implement computed properties with computed()
5
+ 4. Use watch and watchEffect for side effects
6
+ 5. Implement lifecycle hooks with onMounted, onUpdated, etc.
7
+ 6. Utilize provide/inject for dependency injection
8
+
9
+ Folder structure:
10
+ src/
11
+ components/
12
+ composables/
13
+ views/
14
+ router/
15
+ store/
16
+ assets/
17
+ App.vue
18
+ main.ts
19
+
20
+ Additional instructions:
21
+ 1. Use TypeScript for type safety
22
+ 2. Implement proper props and emits definitions
23
+ 3. Utilize Vue 3's Teleport component when needed
24
+ 4. Use Suspense for async components
25
+ 5. Implement proper error handling
26
+ 6. Follow Vue 3 style guide and naming conventions
27
+ 7. Use Vite for fast development and building
You can’t perform that action at this time.
0 commit comments