diff --git a/.vscode/settings.json b/.vscode/settings.json index 3b4db1fc..70312b32 100644 --- a/.vscode/settings.json +++ b/.vscode/settings.json @@ -15,8 +15,8 @@ "css.validate": false, "typescript.tsdk": "node_modules/typescript/lib", "editor.codeActionsOnSave": { - "source.fixAll.eslint": true, - "source.fixAll.stylelint": true + "source.fixAll.eslint": "explicit", + "source.fixAll.stylelint": "explicit" }, "editor.codeActionsOnSaveTimeout": 7500, "stylelint.validate": [ diff --git a/docs/.vuepress/config.js b/docs/.vuepress/config.js index bea80317..0c3c281b 100644 --- a/docs/.vuepress/config.js +++ b/docs/.vuepress/config.js @@ -24,7 +24,11 @@ module.exports = { __dirname, "../../node_modules/@eslint/eslintrc/dist/eslintrc-universal.cjs", ), + "eslint/use-at-your-own-risk": path.resolve( + "./shim/eslint/use-at-your-own-risk.js", + ), eslint$: require.resolve("./shim/eslint"), + "eslint-visitor-keys": require.resolve("./shim/eslint-visitor-keys"), // eslint-disable-next-line n/no-extraneous-require -- demo stylus: require.resolve("stylus/lib/stylus"), glob: require.resolve("./shim/glob"), diff --git a/docs/.vuepress/shim/eslint-visitor-keys.js b/docs/.vuepress/shim/eslint-visitor-keys.js new file mode 100644 index 00000000..58b2f404 --- /dev/null +++ b/docs/.vuepress/shim/eslint-visitor-keys.js @@ -0,0 +1,8 @@ +/* eslint n/no-unsupported-features/es-syntax:0 -- ignore */ +import { + getKeys, + KEYS, + unionWith, +} from "../../../node_modules/eslint-visitor-keys/lib/index.js"; +export { getKeys, KEYS, unionWith }; +export default { getKeys, KEYS, unionWith }; diff --git a/docs/.vuepress/shim/eslint/use-at-your-own-risk.js b/docs/.vuepress/shim/eslint/use-at-your-own-risk.js new file mode 100644 index 00000000..fe2058d3 --- /dev/null +++ b/docs/.vuepress/shim/eslint/use-at-your-own-risk.js @@ -0,0 +1,3 @@ +/* eslint n/no-unsupported-features/es-syntax:0 -- ignore */ +export const builtinRules = new Map(); +export default { builtinRules }; diff --git a/package-lock.json b/package-lock.json index e8fb0da2..6cd2fafc 100644 --- a/package-lock.json +++ b/package-lock.json @@ -9,6 +9,7 @@ "version": "2.5.1", "license": "MIT", "dependencies": { + "@eslint-community/eslint-utils": "^4.4.0", "eslint-utils": "^3.0.0", "lodash": "^4.17.21", "postcss": "^8.4.31", diff --git a/package.json b/package.json index cc4fd4dd..52648e25 100644 --- a/package.json +++ b/package.json @@ -93,6 +93,7 @@ "vuepress": "^1.8.2" }, "dependencies": { + "@eslint-community/eslint-utils": "^4.4.0", "eslint-utils": "^3.0.0", "lodash": "^4.17.21", "postcss": "^8.4.31",