mirror of
https://github.com/m-xlsea/ruoyi-plus-soybean.git
synced 2025-09-24 07:49:47 +08:00
docs(projects): 添加书写规范文档
This commit is contained in:
43
doc/vue+TS书写规范.md
Normal file
43
doc/vue+TS书写规范.md
Normal file
@ -0,0 +1,43 @@
|
||||
推荐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执行
|
Reference in New Issue
Block a user