Skip to content

Commit fb7a84d

Browse files
committed
feat: 版本升级
1 parent da2fa67 commit fb7a84d

File tree

29 files changed

+5949
-8699
lines changed

29 files changed

+5949
-8699
lines changed

.eslintrc.cjs

+3-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
11
/* eslint-env node */
2+
require('@rushstack/eslint-patch/modern-module-resolution');
3+
24
module.exports = {
35
'root': true,
46
'env': {
@@ -9,7 +11,7 @@ module.exports = {
911
'parser': 'vue-eslint-parser',
1012
'parserOptions': {
1113
'parser': '@typescript-eslint/parser',
12-
'ecmaVersion': 2020,
14+
'ecmaVersion': 'latest',
1315
'sourceType': 'module',
1416
'jsxPragma': 'React',
1517
'ecmaFeatures': {

.gitignore

+2
Original file line numberDiff line numberDiff line change
@@ -26,3 +26,5 @@ coverage
2626
*.njsproj
2727
*.sln
2828
*.sw?
29+
30+
*.tsbuildinfo

.vscode/extensions.json

+4-1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
11
{
2-
"recommendations": ["Vue.volar", "Vue.vscode-typescript-vue-plugin"]
2+
"recommendations": [
3+
"Vue.volar",
4+
"dbaeumer.vscode-eslint"
5+
]
36
}

LICENSE

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
MIT License
22

3-
Copyright (c) 2022 midfar
3+
Copyright (c) 2022-2024 midfar
44

55
Permission is hereby granted, free of charge, to any person obtaining a copy
66
of this software and associated documentation files (the "Software"), to deal

README.md

+14-80
Original file line numberDiff line numberDiff line change
@@ -1,105 +1,39 @@
1-
## 简介
1+
# vue3-element-admin
22

3-
这个模板使用了最新的 vue3 和 element-plus UI 框架,vite 构建工具、pinia 状态管理、vue-router 路由管理、mockjs 数据模拟,并集成了 typescript。功能从 Vue Element Admin 移植而来,详细使用可以参考[该文档](https://vue3-element-admin-site.midfar.com/zh/guide/essentials/router-and-nav.html)
3+
This template should help get you started developing with Vue 3 in Vite.
44

5-
## 特性
5+
## Recommended IDE Setup
66

7-
- **最新技术栈**:使用 Vue3/vite3 等前端前沿技术开发
8-
- **TypeScript**: 应用程序级 JavaScript 的语言
9-
- **Mock 数据** 内置 Mock 数据方案
10-
- **权限** 内置完善的动态路由权限生成方案
11-
- **组件** 二次封装了多个常用的组件
7+
[VSCode](https://code.visualstudio.com/) + [Volar](https://marketplace.visualstudio.com/items?itemName=Vue.volar) (and disable Vetur).
128

13-
## 在线示例
9+
## Type Support for `.vue` Imports in TS
1410

15-
[vue3 element admin](https://vue3-element-admin.midfar.com/)
11+
TypeScript cannot handle type information for `.vue` imports by default, so we replace the `tsc` CLI with `vue-tsc` for type checking. In editors, we need [Volar](https://marketplace.visualstudio.com/items?itemName=Vue.volar) to make the TypeScript language service aware of `.vue` types.
1612

17-
[element plus](https://element-plus.midfar.com/)
13+
## Customize configuration
1814

19-
## 准备
20-
开发前请确保熟悉并掌握以下技术栈:
15+
See [Vite Configuration Reference](https://vitejs.dev/config/).
2116

22-
- vue: https://cn.vuejs.org/
23-
- TypeScript:https://www.tslang.cn/index.html
24-
- element-plus:https://element-plus.midfar.com/
25-
- pinia: https://pinia.vuejs.org/zh/
26-
- vue-router: https://router.vuejs.org/zh/
27-
28-
注:开发前请务必阅读上述所有文档。应用至实际项目开发请修改 readme 内容。
29-
30-
## 推荐的 IDE 工具和插件
31-
32-
[VSCode](https://code.visualstudio.com/) + [Volar](https://marketplace.visualstudio.com/items?itemName=Vue.volar) (禁用 Vetur) + [TypeScript Vue Plugin (Volar)](https://marketplace.visualstudio.com/items?itemName=Vue.vscode-typescript-vue-plugin).
33-
34-
## Vite 构建工具配置
35-
36-
参考 [Vite 配置](https://vitejs.dev/config/).
37-
38-
## 主要结构
39-
40-
```
41-
- mock // 模拟数据
42-
- public
43-
- src
44-
- components // 组件
45-
- views // 页面
46-
- tableTemplates // 示例模块
47-
- index.ts
48-
- login // 登录模块
49-
- index.vue
50-
- settings.ts // 全局配置
51-
- main.ts // 入口文件
52-
- types // TypeScript类型
53-
- package.json
54-
- CODE_OF_CONDUCT.md // 框架开发要求
55-
- README.md //框架使用手册
56-
```
57-
58-
## 使用
59-
60-
### 安装依赖
17+
## Project Setup
6118

6219
```sh
6320
npm install
6421
```
6522

66-
### 开发模式连接测试服
23+
### Compile and Hot-Reload for Development
6724

6825
```sh
69-
npm run dev:test
26+
npm run dev
7027
```
7128

72-
### 打包到测试服
29+
### Type-Check, Compile and Minify for Production
7330

7431
```sh
75-
npm run build:test
32+
npm run build
7633
```
7734

78-
### 代码检查 [ESLint](https://eslint.org/)
35+
### Lint with [ESLint](https://eslint.org/)
7936

8037
```sh
8138
npm run lint
8239
```
83-
84-
## 支持环境
85-
86-
现代浏览器。
87-
88-
| IE/Edge | Firefox | Chrome | Safari |
89-
| ---------------- | --------------- | --------------- | --------------- |
90-
| IE10, IE11, Edge | last 2 versions | last 2 versions | last 2 versions |
91-
92-
## TODO
93-
94-
当前问题
95-
96-
- 暂未配置git提交规范。
97-
98-
## 参与贡献
99-
100-
我们非常欢迎你的贡献,你可以通过以下方式和我们一起共建基线框架:
101-
102-
- 联系维护人员 [email protected]
103-
- 提交 pr
104-
- 修复 bug
105-
- 分享实践案例

auto-imports.d.ts

+5-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,8 @@
1-
// Generated by 'unplugin-auto-import'
1+
/* eslint-disable */
2+
/* prettier-ignore */
3+
// @ts-nocheck
4+
// noinspection JSUnusedGlobalSymbols
5+
// Generated by unplugin-auto-import
26
export {}
37
declare global {
48
const ElMessage: typeof import('element-plus/es')['ElMessage']

components.d.ts

+5-20
Original file line numberDiff line numberDiff line change
@@ -1,31 +1,25 @@
1-
// generated by unplugin-vue-components
2-
// We suggest you to commit this file into source control
1+
/* eslint-disable */
2+
// @ts-nocheck
3+
// Generated by unplugin-vue-components
34
// Read more: https://github.com/vuejs/core/pull/3399
4-
import '@vue/runtime-core'
5-
65
export {}
76

8-
declare module '@vue/runtime-core' {
7+
/* prettier-ignore */
8+
declare module 'vue' {
99
export interface GlobalComponents {
1010
BackToTop: typeof import('./src/components/BackToTop/index.vue')['default']
1111
Breadcrumb: typeof import('./src/components/Breadcrumb/index.vue')['default']
1212
DragSelect: typeof import('./src/components/DragSelect/index.vue')['default']
1313
DropdownMenu: typeof import('./src/components/Share/DropdownMenu.vue')['default']
1414
Dropzone: typeof import('./src/components/Dropzone/index.vue')['default']
1515
EditorImage: typeof import('./src/components/Tinymce/components/EditorImage.vue')['default']
16-
ElAlert: typeof import('element-plus/es')['ElAlert']
1716
ElBadge: typeof import('element-plus/es')['ElBadge']
1817
ElBreadcrumb: typeof import('element-plus/es')['ElBreadcrumb']
1918
ElBreadcrumbItem: typeof import('element-plus/es')['ElBreadcrumbItem']
2019
ElButton: typeof import('element-plus/es')['ElButton']
2120
ElCard: typeof import('element-plus/es')['ElCard']
22-
ElCarousel: typeof import('element-plus/es')['ElCarousel']
23-
ElCarouselItem: typeof import('element-plus/es')['ElCarouselItem']
24-
ElCheckbox: typeof import('element-plus/es')['ElCheckbox']
25-
ElCheckboxGroup: typeof import('element-plus/es')['ElCheckboxGroup']
2621
ElCol: typeof import('element-plus/es')['ElCol']
2722
ElConfigProvider: typeof import('element-plus/es')['ElConfigProvider']
28-
ElDatePicker: typeof import('element-plus/es')['ElDatePicker']
2923
ElDialog: typeof import('element-plus/es')['ElDialog']
3024
ElDropdown: typeof import('element-plus/es')['ElDropdown']
3125
ElDropdownItem: typeof import('element-plus/es')['ElDropdownItem']
@@ -37,25 +31,19 @@ declare module '@vue/runtime-core' {
3731
ElMenu: typeof import('element-plus/es')['ElMenu']
3832
ElMenuItem: typeof import('element-plus/es')['ElMenuItem']
3933
ElOption: typeof import('element-plus/es')['ElOption']
40-
ElPagination: typeof import('element-plus/es')['ElPagination']
4134
ElProgress: typeof import('element-plus/es')['ElProgress']
42-
ElRadio: typeof import('element-plus/es')['ElRadio']
4335
ElRadioButton: typeof import('element-plus/es')['ElRadioButton']
4436
ElRadioGroup: typeof import('element-plus/es')['ElRadioGroup']
45-
ElRate: typeof import('element-plus/es')['ElRate']
4637
ElRow: typeof import('element-plus/es')['ElRow']
4738
ElScrollbar: typeof import('element-plus/es')['ElScrollbar']
4839
ElSelect: typeof import('element-plus/es')['ElSelect']
49-
ElSlider: typeof import('element-plus/es')['ElSlider']
5040
ElSubMenu: typeof import('element-plus/es')['ElSubMenu']
5141
ElSwitch: typeof import('element-plus/es')['ElSwitch']
5242
ElTable: typeof import('element-plus/es')['ElTable']
5343
ElTableColumn: typeof import('element-plus/es')['ElTableColumn']
5444
ElTabPane: typeof import('element-plus/es')['ElTabPane']
5545
ElTabs: typeof import('element-plus/es')['ElTabs']
5646
ElTag: typeof import('element-plus/es')['ElTag']
57-
ElTimeline: typeof import('element-plus/es')['ElTimeline']
58-
ElTimelineItem: typeof import('element-plus/es')['ElTimelineItem']
5947
ElTooltip: typeof import('element-plus/es')['ElTooltip']
6048
ElTree: typeof import('element-plus/es')['ElTree']
6149
ElUpload: typeof import('element-plus/es')['ElUpload']
@@ -85,7 +73,4 @@ declare module '@vue/runtime-core' {
8573
UploadExcel: typeof import('./src/components/UploadExcel/index.vue')['default']
8674
VueCountTo: typeof import('./src/components/vue-count-to/vue-countTo.vue')['default']
8775
}
88-
export interface ComponentCustomProperties {
89-
vLoading: typeof import('element-plus/es')['ElLoadingDirective']
90-
}
9176
}

env.d.ts

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
// / <reference types="vite/client" />

index.html

+4-4
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
<!DOCTYPE html>
2-
<html>
2+
<html lang="en">
33
<head>
4-
<meta charset="UTF-8" />
5-
<link rel="icon" href="/favicon.ico" />
6-
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
4+
<meta charset="UTF-8">
5+
<link rel="icon" href="/favicon.ico">
6+
<meta name="viewport" content="width=device-width, initial-scale=1.0">
77
<title>Vite App</title>
88
</head>
99
<body>

0 commit comments

Comments
 (0)