diff options
Diffstat (limited to 'index.js')
-rw-r--r-- | index.js | 57 |
1 files changed, 22 insertions, 35 deletions
@@ -1,42 +1,29 @@ +import babelParser from '@babel/eslint-parser'; +import globals from 'globals'; + export default { - 'root': true, - 'extends': [ - 'eslint:recommended' - ], - 'globals': { - 'wp': true, - }, - 'env': { - 'node': true, - 'es6': true, - 'amd': true, - 'browser': true, - 'jquery': true, - }, - 'parser': '@babel/eslint-parser', - 'parserOptions': { - 'ecmaFeatures': { - 'globalReturn': true, - 'generators': false, - 'objectLiteralDuplicateProperties': false, - 'experimentalObjectRestSpread': true, + languageOptions: { + globals: { + ...globals.browser + }, + parser: babelParser, + parserOptions: { + ecmaFeatures: { + globalReturn: true, + generators: false, + objectLiteralDuplicateProperties: false, + experimentalObjectRestSpread: true, + }, + ecmaVersion: 2017, + sourceType: 'module', + requireConfigFile: false, }, - 'ecmaVersion': 2017, - 'sourceType': 'module', - 'requireConfigFile': false, - }, - 'plugins': [], - 'settings': { - 'import/core-modules': [], - 'import/ignore': [ - 'node_modules', - '\\.(coffee|scss|css|less|hbs|svg|json)$', - ] }, - 'rules': { + + rules: { 'no-console': 0, - 'quotes': ['error', 'single'], - 'semi': ['warn', 'always'], + quotes: ['error', 'single'], + semi: ['warn', 'always'], 'comma-dangle': 0, }, }; |