做专业的水下设备制造商 旁站
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
maochaoying 67f998c324 home screen 2 years ago
.vscode Initial commit 2 years ago
src home screen 2 years ago
.env Initial commit 2 years ago
.gitignore Initial commit 2 years ago
.prettierrc Initial commit 2 years ago
README.md 首屏 2 years ago
index.html some style 2 years ago
logo.ico some style 2 years ago
package-lock.json Initial commit 2 years ago
package.json 引入动画库 2 years ago
vite.config.js some style 2 years ago
yarn.lock 引入动画库 2 years ago

README.md

做铁路相关的设备研发和制造

静态网站,没有后台交互

技术选型

  • 本项目采用的 vue3 + vite + js 脚手架搭建
  • 包管理工具为 Yarn

代码规范

随着团队的不断扩大,每个人都有自己的 coding 风格,但是如果一个项目中的代码存在多种风格,那对于代码的可维护性和可读性都大大减少,所以说一个项目规范对于前端团队来说很重要。

Prettier

1、vscode插件 --- Prettier - Code formatter
2、.prettierrc文件

全局状态管理

使用 pinia

项目结构

├─node_modules // 依赖包
├─public
└─src
    ├─api // 请求方法
    ├─assets // 静态资源
      └─scss // scss文件
    |    └─globalMixin.scss // 全局mixin
    |    └─globalVar.scss // 全局样式变量
    ├─components // 组件
    ├─router // 路由
    ├─service // 封装的工具类
    ├─store // 全局状态管理
      └─modules // 分modules
    ├─views // 视图
    ├─App.vue // 项目根组件
    ├─main.js // 项目入口
    └─style.scss // 全局样式

启动方式

yarn
yarn dev