Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
pentaLiker
DolphinScheduler
提交
51780cc7
DolphinScheduler
项目概览
pentaLiker
/
DolphinScheduler
与 Fork 源项目一致
Fork自
apache / DolphinScheduler
通知
1
Star
1
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
DolphinScheduler
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
前往新版Gitcode,体验更适合开发者的 AI 搜索 >>
提交
51780cc7
编写于
12月 11, 2020
作者:
C
chengshiwen
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
support auto eslint for .js, .vue file on save
上级
e033f81e
变更
5
隐藏空白更改
内联
并排
Showing
5 changed file
with
71 addition
and
7 deletion
+71
-7
dolphinscheduler-ui/.eslintignore
dolphinscheduler-ui/.eslintignore
+7
-0
dolphinscheduler-ui/.eslintrc.yml
dolphinscheduler-ui/.eslintrc.yml
+8
-1
dolphinscheduler-ui/build/config.js
dolphinscheduler-ui/build/config.js
+10
-0
dolphinscheduler-ui/build/webpack.config.dev.js
dolphinscheduler-ui/build/webpack.config.dev.js
+39
-4
dolphinscheduler-ui/package.json
dolphinscheduler-ui/package.json
+7
-2
未找到文件。
dolphinscheduler-ui/.eslintignore
0 → 100644
浏览文件 @
51780cc7
/_test_/
/build/
/dist/
/node/
/node_modules/
/target/
/*.js
dolphinscheduler-ui/.eslintrc.yml
浏览文件 @
51780cc7
...
...
@@ -26,9 +26,16 @@ globals:
Atomics
:
readonly
SharedArrayBuffer
:
readonly
PUBLIC_PATH
:
readonly
$t
:
readonly
parserOptions
:
ecmaVersion
:
2018
sourceType
:
module
plugins
:
-
vue
rules
:
{}
rules
:
vue/script-indent
:
[
'
error'
,
2
,
{
'
baseIndent'
:
1
,
'
switchCase'
:
1
}]
vue/no-unused-components
:
'
off'
no-mixed-operators
:
'
off'
prefer-const
:
'
off'
overrides
:
-
{
'
files'
:
[
'
*.vue'
],
'
rules'
:
{
'
indent'
:
'
off'
}}
dolphinscheduler-ui/build/config.js
浏览文件 @
51780cc7
...
...
@@ -125,6 +125,16 @@ const baseConfig = {
},
module
:
{
rules
:
[
{
test
:
/
\.(
js|vue
)
$/
,
loader
:
'
eslint-loader
'
,
enforce
:
'
pre
'
,
include
:
[
resolve
(
'
src
'
)],
options
:
{
formatter
:
require
(
'
eslint-friendly-formatter
'
),
emitWarning
:
true
}
},
{
test
:
/
\.
vue$/
,
loader
:
'
vue-loader
'
,
...
...
dolphinscheduler-ui/build/webpack.config.dev.js
浏览文件 @
51780cc7
...
...
@@ -19,6 +19,8 @@ const merge = require('webpack-merge')
const
{
assetsDir
,
baseConfig
}
=
require
(
'
./config
'
)
const
MiniCssExtractPlugin
=
require
(
'
mini-css-extract-plugin
'
)
const
ProgressPlugin
=
require
(
'
progress-bar-webpack-plugin
'
)
const
FriendlyErrorsPlugin
=
require
(
'
friendly-errors-webpack-plugin
'
)
const
portfinder
=
require
(
'
portfinder
'
)
const
getEnv
=
require
(
'
env-parse
'
).
getEnv
const
config
=
merge
.
smart
(
baseConfig
,
{
...
...
@@ -33,6 +35,7 @@ const config = merge.smart(baseConfig, {
port
:
getEnv
(
'
DEV_PORT
'
,
8888
),
host
:
getEnv
(
'
DEV_HOST
'
,
'
localhost
'
),
noInfo
:
false
,
overlay
:
{
warnings
:
false
,
errors
:
true
},
historyApiFallback
:
true
,
disableHostCheck
:
true
,
proxy
:
{
...
...
@@ -42,12 +45,12 @@ const config = merge.smart(baseConfig, {
changeOrigin
:
true
}
},
progress
:
fals
e
,
quiet
:
fals
e
,
progress
:
tru
e
,
quiet
:
tru
e
,
stats
:
{
colors
:
true
},
clientLogLevel
:
'
none
'
clientLogLevel
:
'
warning
'
},
plugins
:
[
new
ProgressPlugin
(),
...
...
@@ -57,4 +60,36 @@ const config = merge.smart(baseConfig, {
mode
:
'
development
'
})
module
.
exports
=
config
module
.
exports
=
new
Promise
((
resolve
,
reject
)
=>
{
portfinder
.
basePort
=
process
.
env
.
PORT
||
config
.
devServer
.
port
portfinder
.
getPort
((
err
,
port
)
=>
{
if
(
err
)
{
reject
(
err
)
}
else
{
// publish the new Port, necessary for e2e tests
process
.
env
.
PORT
=
port
// add port to devServer config
config
.
devServer
.
port
=
port
// Add FriendlyErrorsPlugin
config
.
plugins
.
push
(
new
FriendlyErrorsPlugin
({
compilationSuccessInfo
:
{
messages
:
[
`Your application is running here: http://
${
config
.
devServer
.
host
}
:
${
port
}
`
],
},
onErrors
:
()
=>
{
const
notifier
=
require
(
'
node-notifier
'
)
return
(
severity
,
errors
)
=>
{
if
(
severity
!==
'
error
'
)
return
const
error
=
errors
[
0
]
const
filename
=
error
.
file
&&
error
.
file
.
split
(
'
!
'
).
pop
()
notifier
.
notify
({
title
:
packageConfig
.
name
,
message
:
severity
+
'
:
'
+
error
.
name
,
subtitle
:
filename
||
''
})
}
}
}))
resolve
(
config
)
}
})
})
dolphinscheduler-ui/package.json
浏览文件 @
51780cc7
...
...
@@ -8,7 +8,7 @@
"dev"
:
"cross-env NODE_ENV=development webpack-dev-server --config ./build/webpack.config.dev.js"
,
"clean"
:
"rimraf dist"
,
"start"
:
"npm run dev"
,
"lint"
:
"eslint ./src --fix"
,
"lint"
:
"eslint ./src --
ext .js,.vue --
fix"
,
"build:release"
:
"npm run clean && cross-env NODE_ENV=production PUBLIC_PATH=/dolphinscheduler/ui webpack --config ./build/webpack.config.release.js"
},
"dependencies"
:
{
...
...
@@ -55,18 +55,23 @@
"env-parse"
:
"^1.0.5"
,
"eslint"
:
"^6.8.0"
,
"eslint-config-standard"
:
"^14.1.1"
,
"eslint-friendly-formatter"
:
"^4.0.1"
,
"eslint-loader"
:
"^4.0.2"
,
"eslint-plugin-import"
:
"^2.20.2"
,
"eslint-plugin-node"
:
"^11.1.0"
,
"eslint-plugin-promise"
:
"^4.2.1"
,
"eslint-plugin-standard"
:
"^4.0.1"
,
"eslint-plugin-vue"
:
"^
6.2.2
"
,
"eslint-plugin-vue"
:
"^
7.2.0
"
,
"file-loader"
:
"^5.0.2"
,
"friendly-errors-webpack-plugin"
:
"^1.7.0"
,
"globby"
:
"^8.0.1"
,
"html-loader"
:
"^0.5.5"
,
"html-webpack-plugin"
:
"^3.2.0"
,
"mini-css-extract-plugin"
:
"^0.8.2"
,
"node-notifier"
:
"^8.0.0"
,
"node-sass"
:
"^4.14.1"
,
"pack"
:
"^2.2.0"
,
"portfinder"
:
"^1.0.28"
,
"postcss-loader"
:
"^3.0.0"
,
"progress-bar-webpack-plugin"
:
"^1.12.1"
,
"rimraf"
:
"^2.6.2"
,
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录