Skip to content

Commit

Permalink
WIP ♻️ Update lint to v9
Browse files Browse the repository at this point in the history
  • Loading branch information
mcampourcy committed Dec 3, 2024
1 parent dbb781e commit e9b6039
Show file tree
Hide file tree
Showing 5 changed files with 414 additions and 670 deletions.
24 changes: 0 additions & 24 deletions .eslintignore

This file was deleted.

60 changes: 0 additions & 60 deletions .eslintrc.js

This file was deleted.

57 changes: 57 additions & 0 deletions eslint.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,57 @@
const globals = require('globals')
const js = require('@eslint/js');
const babelParser = require('@babel/eslint-parser');
const eslintPluginPrettierRecommended = require('eslint-plugin-prettier/recommended');
const eslintPluginEmber = require('eslint-plugin-ember');
const eslintPluginQunit = require('eslint-plugin-qunit');


module.exports = [
js.configs.recommended,
eslintPluginPrettierRecommended,
eslintPluginEmber.configs.recommended,
eslintPluginQunit.configs.recommended,
{
languageOptions: {
globals: {
...globals.browser,
...globals.node
},
parser: babelParser,
parserOptions: {
requireConfigFile: false,
ecmaVersion: 2018,
sourceType: 'module',
babelOptions: {
plugins: [['@babel/plugin-proposal-decorators', { decoratorsBeforeExport: true }]],
},
},
},
ignores: [
"/blueprints/*/files/",
"/vendor/",
"/dist/",
"/tmp/",
"/bower_components/",
"/node_modules/",
"/coverage/",
"/.node_modules.ember-try/",
"/bower.json.ember-try",
"/package.json.ember-try",
".storybook/**",
"storybook-static/"
],
rules: {
'no-restricted-imports': [
'error',
'lodash',
{
name: '@ember/test-helpers',
importNames: ['render', 'visit', 'find'],
message:
"Please import 'render' from '@1024pix/ember-testing-library'.\n Please import 'visit' from '@1024pix/ember-testing-library'.\n. 'find' should be replaced with '@1024pix/ember-testing-library' 'find...'/'get...'/'query...' methods to enforce accessible usages.",
},
],
}
},
];
Loading

0 comments on commit e9b6039

Please sign in to comment.