lint一下下

This commit is contained in:
Kane 2023-03-27 17:43:54 +08:00
parent ebf4a37529
commit 0c9df7d70d
9 changed files with 926 additions and 370 deletions

File diff suppressed because it is too large Load Diff

View File

@ -11,48 +11,48 @@
"preview-vite": "vite preview"
},
"dependencies": {
"@element-plus/icons-vue": "^1.1.4",
"@element-plus/icons-vue": "^2.1.0",
"@vitejs/plugin-vue": "^4.0.0",
"@wangeditor/editor": "^5.1.23",
"@wangeditor/editor-for-vue": "^5.1.12",
"axios": "^1.2.1",
"core-js": "^3.8.3",
"element-plus": "^2.2.26",
"sass": "^1.56.2",
"axios": "^1.3.4",
"core-js": "^3.29.1",
"element-plus": "^2.3.1",
"sass": "^1.60.0",
"scss": "^0.2.4",
"scss-loader": "^0.0.1",
"vite": "^4.1.4",
"vue": "^3.2.13",
"vue-router": "^4.0.3",
"vuex": "^4.0.0",
"@typescript-eslint/eslint-plugin": "^5.54.0",
"@typescript-eslint/parser": "^5.54.0"
"vue": "^3.2.47",
"vue-router": "^4.1.6",
"vuex": "^4.1.0",
"@typescript-eslint/eslint-plugin": "^5.56.0",
"@typescript-eslint/parser": "^5.56.0"
},
"devDependencies": {
"@babel/core": "^7.12.16",
"@babel/eslint-parser": "^7.12.16",
"@originjs/vite-plugin-commonjs": "^1.0.1",
"@babel/core": "^7.21.3",
"@babel/eslint-parser": "^7.21.3",
"@originjs/vite-plugin-commonjs": "^1.0.3",
"@originjs/vite-plugin-require-context": "1.0.9",
"@vitejs/plugin-vue": "^2.0.1",
"@vitejs/plugin-vue-jsx": "^1.3.2",
"@vue/cli-plugin-babel": "~5.0.0",
"@vue/cli-plugin-eslint": "~5.0.0",
"@vue/cli-plugin-router": "~5.0.0",
"@vue/cli-plugin-vuex": "~5.0.0",
"@vue/cli-service": "~5.0.0",
"@vue/compiler-sfc": "^3.2.26",
"eslint": "^8.35.0",
"@vitejs/plugin-vue": "^4.1.0",
"@vitejs/plugin-vue-jsx": "^3.0.1",
"@vue/cli-plugin-babel": "~5.0.8",
"@vue/cli-plugin-eslint": "~5.0.8",
"@vue/cli-plugin-router": "~5.0.8",
"@vue/cli-plugin-vuex": "~5.0.8",
"@vue/cli-service": "~5.0.8",
"@vue/compiler-sfc": "^3.2.47",
"eslint": "^8.36.0",
"node-sass": "^8.0.0",
"sass-loader": "^13.2.0",
"vite": "^2.7.2",
"sass-loader": "^13.2.1",
"vite": "^4.2.1",
"vite-plugin-env-compatible": "^1.1.1",
"vite-plugin-html": "3.2.0",
"vue-cli-plugin-element-plus": "~0.0.13",
"webpack": "^5.75.0",
"webpack": "^5.76.3",
"webpack-cli": "^5.0.1",
"eslint-config-recommended": "^4.1.0",
"eslint-config-standard-with-typescript": "^34.0.0",
"eslint-plugin-vue": "^9.9.0",
"eslint-config-standard-with-typescript": "^34.0.1",
"eslint-plugin-vue": "^9.10.0",
"sass": "^1.58.3"
}
}

View File

@ -4,24 +4,24 @@
* @LastEditors: Kane
* @LastEditTime: 2023-02-22 17:10:18
* @FilePath: /IT/src/components/svg/SvgIcon.vue
* @Description:
*
* Copyright (c) ${2022} by Kane, All Rights Reserved.
* @Description:
*
* Copyright (c) ${2022} by Kane, All Rights Reserved.
-->
<template>
svg-icon:{{ this.iconName }}
svg-icon:{{ iconName }}
</template>
<script>
export default {
name: "svg-icon",
name: "SvgIcon",
props: ["icon",],
data()
{
return {
iconName: "",
};
},
props: ["icon",],
created()
{
console.log("svg");
@ -31,4 +31,4 @@ export default {
};
</script>
<style scoped></style>
<style scoped></style>

View File

@ -8,15 +8,15 @@
*
* Copyright (c) ${2022} by Kane, All Rights Reserved.
*/
import { createStore } from 'vuex';
import { createStore } from "vuex";
import app from "./modules/app";
import requirement from "./modules/requirement";
const store = createStore({
modules: {
app,
requirement,
},
modules: {
app,
requirement,
},
});
export default store;

View File

@ -4,9 +4,9 @@
* @LastEditors: Kane
* @LastEditTime: 2023-01-06 15:26:46
* @FilePath: \admin_system\src\views\news\News.vue
* @Description:
*
* Copyright (c) ${2022} by Kane, All Rights Reserved.
* @Description:
*
* Copyright (c) ${2022} by Kane, All Rights Reserved.
-->
<template>
信息管理
@ -14,10 +14,10 @@
<script>
export default {
name: "NewsPage"
name: "NewsPage",
};
</script>
<style scoped>
</style>
</style>

View File

@ -4,19 +4,24 @@
* @LastEditors: Kane
* @LastEditTime: 2023-01-08 19:26:26
* @FilePath: \admin_system\src\views\news\NewsEdit.vue
* @Description:
*
* Copyright (c) ${2022} by Kane, All Rights Reserved.
* @Description:
*
* Copyright (c) ${2022} by Kane, All Rights Reserved.
-->
<template>
信息编辑:{{ getCount }}
<br>
<el-button type="danger" @click="this.add">计数加一</el-button>
<SvgIcon icon="house"></SvgIcon>
<el-button
type="danger"
@click="add"
>
计数加一
</el-button>
<SvgIcon icon="house" />
</template>
<script>
//import { ElMessage } from 'element-plus';
// import { ElMessage } from 'element-plus';
export default {
name: "NewsEdit",
@ -32,21 +37,21 @@ export default {
return this.$store.state.app.count;
},
},
created()
{
this.store = this.$store;
},
methods: {
add()
{
let count = this.store.state.app.count + 1;
const count = this.store.state.app.count + 1;
this.store.commit("app/SET_COUNT", count);
},
},
created()
{
this.store = this.$store;
}
};
</script>
<style scoped>
</style>
</style>

View File

@ -4,9 +4,9 @@
* @LastEditors: Kane
* @LastEditTime: 2023-01-06 19:23:29
* @FilePath: \admin_system\src\views\news\NewsTest.vue
* @Description:
*
* Copyright (c) ${2022} by Kane, All Rights Reserved.
* @Description:
*
* Copyright (c) ${2022} by Kane, All Rights Reserved.
-->
<!--
* @Author: Kane
@ -14,9 +14,9 @@
* @LastEditors: Kane
* @LastEditTime: 2023-01-06 15:26:46
* @FilePath: \admin_system\src\views\news\News.vue
* @Description:
*
* Copyright (c) ${2022} by Kane, All Rights Reserved.
* @Description:
*
* Copyright (c) ${2022} by Kane, All Rights Reserved.
-->
<template>
信息管理
@ -24,10 +24,10 @@
<script>
export default {
name: "NewsPage"
name: "NewsPage",
};
</script>
<style scoped>
</style>
</style>

View File

@ -8,60 +8,60 @@
*
* Copyright (c) ${2022} by Kane, All Rights Reserved.
*/
import { defineConfig } from 'vite';
import path from 'path';
import vue from '@vitejs/plugin-vue';
import vueJsx from '@vitejs/plugin-vue-jsx';
import ViteRequireContext from '@originjs/vite-plugin-require-context';
import envCompatible from 'vite-plugin-env-compatible';
import { createHtmlPlugin } from 'vite-plugin-html';
import { viteCommonjs } from '@originjs/vite-plugin-commonjs';
import { defineConfig } from "vite";
import path from "path";
import vue from "@vitejs/plugin-vue";
import vueJsx from "@vitejs/plugin-vue-jsx";
import ViteRequireContext from "@originjs/vite-plugin-require-context";
import envCompatible from "vite-plugin-env-compatible";
import { createHtmlPlugin } from "vite-plugin-html";
import { viteCommonjs } from "@originjs/vite-plugin-commonjs";
// https://vitejs.dev/config/
export default defineConfig({
resolve: {
alias: [
{
find: /^~/,
replacement: '',
},
{
find: '@',
replacement: path.resolve(__dirname, 'src'),
},
resolve: {
alias: [
{
find: /^~/,
replacement: "",
},
{
find: "@",
replacement: path.resolve(__dirname, "src"),
},
],
extensions: [
".mjs",
".js",
".ts",
".jsx",
".tsx",
".json",
".vue",
],
},
plugins: [
vue(),
vueJsx(),
ViteRequireContext(),
viteCommonjs(),
envCompatible(),
createHtmlPlugin({
inject: {
data: {
title: "CPIC-IT-Console",
},
},
}),
],
extensions: [
'.mjs',
'.js',
'.ts',
'.jsx',
'.tsx',
'.json',
'.vue',
],
},
plugins: [
vue(),
vueJsx(),
ViteRequireContext(),
viteCommonjs(),
envCompatible(),
createHtmlPlugin({
inject: {
data: {
title: 'CPIC-IT-Console',
},
},
}),
],
base: './',
server: {
strictPort: false,
port: 8001,
host: 'localhost',
open: true,
},
build: {
outDir: 'dist',
},
base: "./",
server: {
strictPort: false,
port: 8001,
host: "localhost",
open: true,
},
build: {
outDir: "dist",
},
});

View File

@ -20,35 +20,35 @@
// }
// );
module.exports = {
transpileDependencies: true,
devServer: {
open: true,
host: "localhost",
port: 8000,
},
// chainWebpack: (config) =>
// {
// // svg 图标解析
// const svgRule = config.module.rule("svg"); //默认规则赋给 subRule 变量
// svgRule.uses.clear(); // 清除已有的所有规则。
// svgRule // 添加要替换的规则
// .use("svg-sprite-loader")
// .loader("svg-sprite-loader")
// .options({
// symbolId: "icon-[name]",
// include: ["./src/components/svg/icons",], // 特别注意的目录路径
// });
// 配置base64转换规则
// config.module
// .rule('images')
// .use('url-loader')
// .loader('url-loader')
// .tap(options => Object.assign(options, { limit: 1 }));
transpileDependencies: true,
devServer: {
open: true,
host: "localhost",
port: 8000,
},
// chainWebpack: (config) =>
// {
// // svg 图标解析
// const svgRule = config.module.rule("svg"); //默认规则赋给 subRule 变量
// svgRule.uses.clear(); // 清除已有的所有规则。
// svgRule // 添加要替换的规则
// .use("svg-sprite-loader")
// .loader("svg-sprite-loader")
// .options({
// symbolId: "icon-[name]",
// include: ["./src/components/svg/icons",], // 特别注意的目录路径
// });
// 配置base64转换规则
// config.module
// .rule('images')
// .use('url-loader')
// .loader('url-loader')
// .tap(options => Object.assign(options, { limit: 1 }));
// 载入项目分析工具
// config.plugin('webpack-bundle-analyzer').use(require('webpack-bundle-analyzer').BundleAnalyzerPlugin)
// },
//打包输出目录
publicPath: "./",
outputDir: "dist",
// 载入项目分析工具
// config.plugin('webpack-bundle-analyzer').use(require('webpack-bundle-analyzer').BundleAnalyzerPlugin)
// },
//打包输出目录
publicPath: "./",
outputDir: "dist",
};