mirror of
https://github.com/hasura/graphql-engine.git
synced 2024-12-15 01:12:56 +03:00
55307f1797
PR-URL: https://github.com/hasura/graphql-engine-mono/pull/6991 Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> Co-authored-by: Nicolas Inchauspe <710410+nicoinch@users.noreply.github.com> GitOrigin-RevId: 88173064e50d3e05cd1606f7c2a5b9edf1d5857b
103 lines
3.6 KiB
JSON
103 lines
3.6 KiB
JSON
{
|
|
"extends": ["plugin:@nrwl/nx/react", "../../../.eslintrc.json"],
|
|
"ignorePatterns": ["!**/*"],
|
|
"globals": {
|
|
"__DEVELOPMENT__": true,
|
|
"__CLIENT__": true,
|
|
"__SERVER__": true,
|
|
"__DISABLE_SSR__": true,
|
|
"__DEVTOOLS__": true,
|
|
"socket": true,
|
|
"webpackIsomorphicTools": true,
|
|
"CONSOLE_ASSET_VERSION": true
|
|
},
|
|
"overrides": [
|
|
{
|
|
"files": ["*.ts", "*.tsx", "*.js", "*.jsx"],
|
|
"rules": {
|
|
"react/forbid-dom-props": [
|
|
"error",
|
|
{
|
|
"forbid": [
|
|
{
|
|
"propName": "data-analytics-name",
|
|
"message": "Analytics attributes (data-analytics-name) should be added through the Analytics component/utilities"
|
|
},
|
|
{
|
|
"propName": "data-trackid",
|
|
"message": "Analytics attributes (data-trackid) should be added through the Analytics component/utilities"
|
|
},
|
|
{
|
|
"propName": "data-heap-redact-text",
|
|
"message": "Analytics attributes (data-heap-redact-text) should be added through the Analytics component/utilities"
|
|
},
|
|
{
|
|
"propName": "data-heap-redact-attributes",
|
|
"message": "Analytics attributes (data-heap-redact-attributes) should be added through the Analytics component/utilities"
|
|
}
|
|
]
|
|
}
|
|
],
|
|
"react/forbid-component-props": [
|
|
"error",
|
|
{
|
|
"forbid": [
|
|
{
|
|
"propName": "data-analytics-name",
|
|
"message": "Analytics attributes (data-analytics-name) should be added through the Analytics component/utilities"
|
|
},
|
|
{
|
|
"propName": "data-trackid",
|
|
"message": "Analytics attributes (data-trackid) should be added through the Analytics component/utilities"
|
|
},
|
|
{
|
|
"propName": "data-heap-redact-text",
|
|
"message": "Analytics attributes (data-heap-redact-text) should be added through the Analytics component/utilities"
|
|
},
|
|
{
|
|
"propName": "data-heap-redact-attributes",
|
|
"message": "Analytics attributes (data-heap-redact-attributes) should be added through the Analytics component/utilities"
|
|
}
|
|
]
|
|
}
|
|
],
|
|
"import/first": "warn",
|
|
"no-restricted-globals": "warn",
|
|
"no-case-declarations": "warn",
|
|
"@typescript-eslint/no-unused-expressions": "warn",
|
|
"@typescript-eslint/no-empty-function": "warn",
|
|
"@typescript-eslint/no-empty-interface": "warn",
|
|
"no-prototype-builtins": "warn",
|
|
"react-hooks/rules-of-hooks": "warn"
|
|
}
|
|
},
|
|
{
|
|
"files": ["*.ts", "*.tsx"],
|
|
"rules": {
|
|
"import/first": "warn",
|
|
"no-restricted-globals": "warn",
|
|
"no-case-declarations": "warn",
|
|
"@typescript-eslint/no-unused-expressions": "warn",
|
|
"@typescript-eslint/no-empty-function": "warn",
|
|
"@typescript-eslint/no-empty-interface": "warn",
|
|
"no-prototype-builtins": "warn",
|
|
"react-hooks/rules-of-hooks": "warn"
|
|
}
|
|
},
|
|
{
|
|
"files": ["*.js", "*.jsx"],
|
|
"parser": "@babel/eslint-parser",
|
|
"rules": {
|
|
"import/first": "warn",
|
|
"no-restricted-globals": "warn",
|
|
"no-case-declarations": "warn",
|
|
"@typescript-eslint/no-unused-expressions": "warn",
|
|
"@typescript-eslint/no-empty-function": "warn",
|
|
"@typescript-eslint/no-empty-interface": "warn",
|
|
"no-prototype-builtins": "warn",
|
|
"react-hooks/rules-of-hooks": "warn"
|
|
}
|
|
}
|
|
]
|
|
}
|