提交 62f1816e authored 作者: lihuihui's avatar lihuihui

update

上级 d8d5e149
This source diff could not be displayed because it is too large. You can view the blob instead.
...@@ -24,7 +24,6 @@ ...@@ -24,7 +24,6 @@
"vuex": "^3.6.2" "vuex": "^3.6.2"
}, },
"devDependencies": { "devDependencies": {
"@rollup/plugin-eslint": "^8.0.1",
"ali-oss": "^6.16.0", "ali-oss": "^6.16.0",
"chalk": "^4.1.2", "chalk": "^4.1.2",
"cross-env": "^7.0.3", "cross-env": "^7.0.3",
...@@ -35,8 +34,9 @@ ...@@ -35,8 +34,9 @@
"eslint-plugin-promise": "^5.1.0", "eslint-plugin-promise": "^5.1.0",
"eslint-plugin-vue": "^7.17.0", "eslint-plugin-vue": "^7.17.0",
"sass": "1.32.13", "sass": "1.32.13",
"vite": "^2.5.3", "vite": "^2.9.8",
"vite-plugin-vue2": "^1.8.1", "vite-plugin-checker": "^0.4.6",
"vite-plugin-vue2": "^2.0.0",
"vue-template-compiler": "^2.6.14" "vue-template-compiler": "^2.6.14"
} }
} }
...@@ -39,8 +39,8 @@ export default { ...@@ -39,8 +39,8 @@ export default {
this.dispatch('ElFormItem', 'el.form.blur', editor.getContent()) this.dispatch('ElFormItem', 'el.form.blur', editor.getContent())
}, },
dispatch(componentName, eventName, params) { dispatch(componentName, eventName, params) {
var parent = this.$parent || this.$root let parent = this.$parent || this.$root
var name = parent.$options.componentName let name = parent.$options.componentName
while (parent && (!name || name !== componentName)) { while (parent && (!name || name !== componentName)) {
parent = parent.$parent parent = parent.$parent
......
function cmOption(mod) { function cmOption(mod) {
let option = {}; let option = {}
switch (mod) { switch (mod) {
case "js": case 'js':
option = { option = {
mode: { name: "javascript" } mode: { name: 'javascript' }
}; }
break; break
case "css": case 'css':
option = { option = {
mode: { name: "css" } mode: { name: 'css' }
}; }
break; break
case "html": case 'html':
option = { option = {
mode: "text/html" mode: 'text/html'
}; }
break; break
case "json": case 'json':
option = { option = {
mode: { name: "javascript", json: true } mode: { name: 'javascript', json: true }
}; }
break; break
} }
return option; return option
} }
export { export { cmOption }
cmOption
}
\ No newline at end of file
...@@ -2,10 +2,17 @@ import fs from 'fs' ...@@ -2,10 +2,17 @@ import fs from 'fs'
import path from 'path' import path from 'path'
import { defineConfig } from 'vite' import { defineConfig } from 'vite'
import { createVuePlugin } from 'vite-plugin-vue2' import { createVuePlugin } from 'vite-plugin-vue2'
import eslint from '@rollup/plugin-eslint' import checker from 'vite-plugin-checker'
export default defineConfig({ export default defineConfig({
base: process.env.BUILD_ENV === 'prod' ? 'https://webapp-pub.ezijing.com/website/prod/x-training/' : '/', base: process.env.BUILD_ENV === 'prod' ? 'https://webapp-pub.ezijing.com/website/prod/x-training/' : '/',
plugins: [eslint({ include: '**/*.+(vue|js|jsx|ts|tsx)' }), createVuePlugin()], plugins: [
checker({
eslint: {
lintCommand: 'eslint "./src/**/*.{vue,js,jsx,ts,tsx}"'
}
}),
createVuePlugin()
],
server: { server: {
open: true, open: true,
host: 'dev.ezijing.com', host: 'dev.ezijing.com',
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论