Skip to content

Commit

Permalink
feat: add support for ESLint 9
Browse files Browse the repository at this point in the history
Closes: #49
  • Loading branch information
targos committed Oct 5, 2024
1 parent 4d90e2b commit b2cd944
Show file tree
Hide file tree
Showing 4 changed files with 2 additions and 17 deletions.
11 changes: 0 additions & 11 deletions base.js
Original file line number Diff line number Diff line change
@@ -1,12 +1,10 @@
import importPlugin from 'eslint-plugin-import';
import noLookaheadLookbehindRegexp from 'eslint-plugin-no-lookahead-lookbehind-regexp';
import globals from 'globals';

export default [
{
plugins: {
import: importPlugin,
'no-lookahead-lookbehind-regexp': noLookaheadLookbehindRegexp,
},

linterOptions: {
Expand Down Expand Up @@ -280,15 +278,6 @@ export default [
],
'import/no-named-default': 'error',
//#endregion

//#region No lookbehind plugin (/~https://github.com/JonasBa/eslint-plugin-no-lookahead-lookbehind-regexp)
'no-lookahead-lookbehind-regexp/no-lookahead-lookbehind-regexp': [
'error',
'no-lookbehind',
'no-negative-lookbehind',
{ browserslist: false },
],
//#endregion
},
},
{
Expand Down
5 changes: 2 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -37,15 +37,14 @@
"dependencies": {
"eslint-plugin-import": "^2.31.0",
"eslint-plugin-jsdoc": "^50.3.1",
"eslint-plugin-no-lookahead-lookbehind-regexp": "^0.3.0",
"eslint-plugin-unicorn": "^56.0.0",
"globals": "^15.10.0"
},
"peerDependencies": {
"eslint": "^8.57.0"
"eslint": "^8.57.0 || ^9.12.0"
},
"devDependencies": {
"eslint": "8.57.0",
"eslint": "9.12.0",
"prettier": "^3.3.3"
}
}
2 changes: 0 additions & 2 deletions test/not-ok.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,6 @@ function A() {
this.x = 1;
}

useIt(/test(?<=text)/);

useIt(
['a', 'b', 'c'].reduce((prev, curr) => {
prev[curr] = true;
Expand Down
1 change: 0 additions & 1 deletion test/test.js
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@ const errors = notOkResult.messages
assert.deepStrictEqual(errors, [
'import/no-absolute-path',
'no-console',
'no-lookahead-lookbehind-regexp/no-lookahead-lookbehind-regexp',
'no-redeclare',
'no-unused-vars',
'no-unused-vars',
Expand Down

0 comments on commit b2cd944

Please sign in to comment.