62f63e14d2
This is a mixed codebase and still uses classic components
71 lines
1.5 KiB
JavaScript
71 lines
1.5 KiB
JavaScript
'use strict';
|
|
|
|
module.exports = {
|
|
root: true,
|
|
parser: 'babel-eslint',
|
|
parserOptions: {
|
|
ecmaVersion: 2018,
|
|
sourceType: 'module',
|
|
ecmaFeatures: {
|
|
legacyDecorators: true,
|
|
},
|
|
},
|
|
globals: {
|
|
server: true,
|
|
},
|
|
env: {
|
|
browser: true,
|
|
},
|
|
plugins: ['ember'],
|
|
extends: ['eslint:recommended', 'plugin:ember/recommended', 'plugin:prettier/recommended'],
|
|
rules: {
|
|
'ember/classic-decorator-hooks': 'error',
|
|
'ember/classic-decorator-no-classic-methods': 'error',
|
|
'ember/no-get': 'off',
|
|
'ember/no-mixins': 'off',
|
|
'ember/no-classic-classes': 'off',
|
|
'ember/no-computed-properties-in-native-classes': 'off',
|
|
'ember/no-classic-components': 'off',
|
|
},
|
|
overrides: [
|
|
// node files
|
|
{
|
|
files: [
|
|
'.eslintrc.js',
|
|
'.prettierrc.js',
|
|
'.template-lintrc.js',
|
|
'ember-cli-build.js',
|
|
'testem.js',
|
|
'blueprints/*/index.js',
|
|
'config/**/*.js',
|
|
'lib/*/index.js',
|
|
'server/**/*.js',
|
|
],
|
|
parserOptions: {
|
|
sourceType: 'script',
|
|
},
|
|
env: {
|
|
browser: false,
|
|
node: true,
|
|
},
|
|
plugins: ['node'],
|
|
rules: {
|
|
// this can be removed once the following is fixed
|
|
// https://github.com/mysticatea/eslint-plugin-node/issues/77
|
|
'node/no-unpublished-require': 'off',
|
|
},
|
|
},
|
|
{
|
|
files: ['stories/**/*.js'],
|
|
parserOptions: {
|
|
sourceType: 'module',
|
|
},
|
|
env: {
|
|
browser: false,
|
|
node: true,
|
|
},
|
|
plugins: ['node'],
|
|
},
|
|
],
|
|
};
|