webhook/node_modules/eslint-plugin-github/lib/configs/browser.js

30 lines
901 B
JavaScript
Raw Normal View History

module.exports = {
env: {
browser: true
},
2022-11-10 11:43:16 +01:00
plugins: ['github', 'escompat'],
extends: ['plugin:escompat/recommended'],
rules: {
2022-11-10 11:43:16 +01:00
'escompat/no-dynamic-imports': 'off',
'github/async-currenttarget': 'error',
'github/async-preventdefault': 'error',
'github/get-attribute': 'error',
'github/no-blur': 'error',
'github/no-dataset': 'error',
'github/no-innerText': 'error',
2022-11-10 11:43:16 +01:00
'github/no-inner-html': 'error',
'github/unescaped-html-literal': 'error',
'github/no-useless-passive': 'error',
'github/require-passive-events': 'error',
2022-11-10 11:43:16 +01:00
'github/prefer-observers': 'error',
'import/no-nodejs-modules': 'error',
'no-restricted-syntax': [
'error',
{
selector: "NewExpression[callee.name='URL'][arguments.length=1]",
message: 'Please pass in `window.location.origin` as the 2nd argument to `new URL()`'
}
]
}
}