Skip to content

Commit

Permalink
fix: tweak strictness of ts-eslint rules
Browse files Browse the repository at this point in the history
  • Loading branch information
nihalgonsalves committed Aug 13, 2024
1 parent 8be2812 commit 376a7ad
Showing 1 changed file with 11 additions and 1 deletion.
12 changes: 11 additions & 1 deletion eslint.config.shared.js
Original file line number Diff line number Diff line change
Expand Up @@ -104,11 +104,12 @@ export default tseslint.config(
"**/*{.,_}{test,spec}.{js,jsx}",
"**/*{.,_}{test,spec}.{ts,tsx}",
"**/*.config.{js,ts,cjs,mjs,cts,mts}",
"**/*.stories.@(ts|tsx|js|jsx|mjs|cjs)",
],
optionalDependencies: false,
},
],
"import/no-default-export": "error",
"import/no-default-export": ["error"],
"import/order": [
"error",
{
Expand Down Expand Up @@ -157,15 +158,24 @@ export default tseslint.config(
assertionStyle: "never",
},
],
"@typescript-eslint/prefer-nullish-coalescing": [
"error",
{ ignorePrimitives: { boolean: true, string: true } },
],
"@typescript-eslint/strict-boolean-expressions": [
"error",
{ allowNullableBoolean: true, allowNullableString: true },
],
"@typescript-eslint/restrict-template-expressions": [
"error",
{ allowNumber: true },
],
"@typescript-eslint/promise-function-async": "error",
"@typescript-eslint/method-signature-style": "error",
"@typescript-eslint/no-import-type-side-effects": "error",
"@typescript-eslint/require-array-sort-compare": "error",
"@typescript-eslint/switch-exhaustiveness-check": "error",
"@typescript-eslint/require-await": "off",
},
settings: {
"import/extensions": [
Expand Down

0 comments on commit 376a7ad

Please sign in to comment.