mirror of
https://github.com/grafana/grafana.git
synced 2025-08-03 03:13:49 +08:00
Chore: use fork-ts-checker plugin for eslint check (#25631)
* Use fork-ts-checker for eslint check * Fix lint issue * Add packages to lint * Add comments to webpack configs
This commit is contained in:
@ -66,13 +66,6 @@ module.exports = merge(common, {
|
||||
],
|
||||
},
|
||||
},
|
||||
{
|
||||
loader: 'eslint-loader',
|
||||
options: {
|
||||
emitError: true,
|
||||
emitWarning: true,
|
||||
},
|
||||
},
|
||||
],
|
||||
},
|
||||
require('./sass.rule.js')({
|
||||
@ -94,8 +87,26 @@ module.exports = merge(common, {
|
||||
},
|
||||
plugins: [
|
||||
new ForkTsCheckerWebpackPlugin({
|
||||
checkSyntacticErrors: true,
|
||||
memoryLimit: 4096,
|
||||
eslint: {
|
||||
enabled: true,
|
||||
files: [
|
||||
'public/app/**/*.{ts,tsx}',
|
||||
// this can't be written like this packages/**/src/**/*.ts because it throws an error
|
||||
'packages/grafana-ui/src/**/*.{ts,tsx}',
|
||||
'packages/grafana-data/src/**/*.{ts,tsx}',
|
||||
'packages/grafana-runtime/src/**/*.{ts,tsx}',
|
||||
'packages/grafana-e2e-selectors/src/**/*.{ts,tsx}',
|
||||
'packages/jaeger-ui-components/src/**/*.{ts,tsx}',
|
||||
],
|
||||
},
|
||||
typescript: {
|
||||
mode: 'write-references',
|
||||
memoryLimit: 4096,
|
||||
diagnosticOptions: {
|
||||
semantic: true,
|
||||
syntactic: true,
|
||||
},
|
||||
},
|
||||
}),
|
||||
new MiniCssExtractPlugin({
|
||||
filename: 'grafana.[name].[hash].css',
|
||||
|
Reference in New Issue
Block a user