2022-05-03 22:32:16 +08:00
|
|
|
module.exports = {
|
2022-12-10 03:34:25 +08:00
|
|
|
plugins: ["matrix-org"],
|
2023-06-30 23:43:28 +08:00
|
|
|
extends: [
|
|
|
|
"prettier",
|
|
|
|
"plugin:matrix-org/react",
|
|
|
|
"plugin:matrix-org/a11y",
|
|
|
|
"plugin:matrix-org/typescript",
|
|
|
|
],
|
|
|
|
parserOptions: {
|
|
|
|
ecmaVersion: 2018,
|
|
|
|
sourceType: "module",
|
|
|
|
project: ["./tsconfig.json"],
|
|
|
|
},
|
2022-12-10 03:34:25 +08:00
|
|
|
env: {
|
|
|
|
browser: true,
|
|
|
|
node: true,
|
|
|
|
},
|
|
|
|
parserOptions: {
|
|
|
|
ecmaVersion: "latest",
|
|
|
|
sourceType: "module",
|
|
|
|
},
|
|
|
|
rules: {
|
|
|
|
"jsx-a11y/media-has-caption": ["off"],
|
|
|
|
},
|
|
|
|
overrides: [
|
|
|
|
{
|
2023-09-19 00:58:49 +08:00
|
|
|
files: ["src/**/*.{ts,tsx}", "test/**/*.{ts,tsx}"],
|
2022-12-10 03:34:25 +08:00
|
|
|
extends: [
|
|
|
|
"plugin:matrix-org/typescript",
|
2022-05-03 22:32:16 +08:00
|
|
|
"plugin:matrix-org/react",
|
|
|
|
"prettier",
|
2022-12-10 03:34:25 +08:00
|
|
|
],
|
|
|
|
rules: {
|
|
|
|
// We're aiming to convert this code to strict mode
|
|
|
|
"@typescript-eslint/no-non-null-assertion": "off",
|
2023-09-26 01:04:34 +08:00
|
|
|
// We should use the js-sdk logger, never console directly.
|
|
|
|
"no-console": ["error"],
|
2022-12-10 03:34:25 +08:00
|
|
|
},
|
2022-05-03 22:32:16 +08:00
|
|
|
},
|
2022-12-10 03:34:25 +08:00
|
|
|
],
|
|
|
|
settings: {
|
|
|
|
react: {
|
|
|
|
version: "detect",
|
2022-05-03 22:32:16 +08:00
|
|
|
},
|
2022-12-10 03:34:25 +08:00
|
|
|
},
|
2022-05-03 22:32:16 +08:00
|
|
|
};
|