wcb/eslint.config.mjs
Ayo 2da6cd5afc
Some checks are pending
Tests / Unit (push) Waiting to run
Tests / E2E (push) Waiting to run
feat: new cem analyzer plugin (cem-plugin)
2026-07-19 21:06:22 +02:00

32 lines
920 B
JavaScript

import globals from 'globals'
import pluginJs from '@eslint/js'
import jsdoc from 'eslint-plugin-jsdoc'
/** @type {import('eslint').Linter.Config[]} */
export default [
{ languageOptions: { globals: globals.browser } },
pluginJs.configs.recommended,
jsdoc.configs['flat/recommended'],
{
rules: {
'no-unused-vars': 'warn',
},
},
// Config, build, and script files run in Node — give them Node globals
// (e.g. `process`) on top of the browser defaults.
{
files: ['**/*.config.{js,mjs,cjs}', 'scripts/**/*.{js,mjs}'],
languageOptions: { globals: globals.node },
},
// The Storybook config files and the CEM analyzer config run in Node.
{
files: [
'storybook/.storybook/*.js',
'**/custom-elements-manifest.config.mjs',
],
languageOptions: { globals: globals.node },
},
{
ignores: ['site/*', '**/dist/*', 'storybook/storybook-static/*'],
},
]