ruoyi-plus-soybean/doc/vue+TS书写规范.md

44 lines
642 B
Markdown
Raw Normal View History

推荐script-setup写法
第一部分书写
template
第二部分
script
一、import的顺序
1.vue模块
2.vue相关类型
3.vue-router模块
4.vue-router相关类型
5.UI框架模块
6.UI框架相关类型
7.第三方依赖
8.第三方依赖相关类型
9.@/enum
10.@/setting
11.@/plugins
12.@/layouts
13.@/views
14.@/components
15.@/hooks
16.@/store
17.@/context
18.@/router
19.@/service
20.@/utils
21.@/interface
22.@/assets
23.相对路径依赖
二、TS类型声明
三、defineProps、defineEmits、defineExpose、withDefaults
四、响应式use函数
五、变量、函数声明
六、vue生命周期函数、nextTick执行