Files
insights-js/packages/rrweb/.eslintrc.js

47 lines
1.9 KiB
JavaScript

module.exports = {
root: true,
extends: ['eslint:recommended', 'plugin:@typescript-eslint/recommended'],
parser: '@typescript-eslint/parser',
plugins: ['@typescript-eslint'],
env: {
browser: true,
es2020: true,
node: true,
},
rules: {
// Disable prettier - rrweb formatting is normalized separately
'prettier/prettier': 'off',
// Disable rules that conflict with rrweb's codebase
'@typescript-eslint/no-explicit-any': 'off',
'@typescript-eslint/no-unused-vars': 'off',
'@typescript-eslint/ban-ts-comment': 'off',
'@typescript-eslint/no-non-null-assertion': 'off',
'@typescript-eslint/no-empty-function': 'off',
'@typescript-eslint/no-this-alias': 'off',
'@typescript-eslint/no-unused-expressions': 'off',
'@typescript-eslint/no-require-imports': 'off',
'no-prototype-builtins': 'off',
'no-useless-escape': 'off',
'no-empty': 'off',
'prefer-const': 'off',
'no-constant-condition': 'off',
'no-extra-semi': 'off',
'no-var': 'off',
'no-global-assign': 'off',
// insights-js specific rules that don't apply to rrweb
'insights-js/no-direct-array-check': 'off',
'insights-js/no-direct-boolean-check': 'off',
'insights-js/no-direct-document-check': 'off',
'insights-js/no-direct-function-check': 'off',
'insights-js/no-direct-navigator-check': 'off',
'insights-js/no-direct-null-check': 'off',
'insights-js/no-direct-number-check': 'off',
'insights-js/no-direct-object-check': 'off',
'insights-js/no-direct-string-check': 'off',
'insights-js/no-direct-undefined-check': 'off',
'insights-js/no-direct-window-check': 'off',
'compat/compat': 'off',
},
ignorePatterns: ['dist/', 'node_modules/', '*.js', '*.cjs', '*.mjs'],
}