Skip to content

Commit

Permalink
fix(eslint): put restrict-template-expressions into rules for which t…
Browse files Browse the repository at this point in the history
…ypes are required
  • Loading branch information
Isokaeder committed May 15, 2024
1 parent c0407c7 commit 81111b2
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 12 deletions.
2 changes: 1 addition & 1 deletion packages/eslint-config/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -61,5 +61,5 @@
},
"type": "module",
"types": "./dist/mjs/index.d.ts",
"version": "0.0.2"
"version": "0.0.3"
}
22 changes: 11 additions & 11 deletions packages/eslint-config/source/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -130,17 +130,6 @@ const baseConfig = tseslint.config({
{ argsIgnorePattern: '^_', destructuredArrayIgnorePattern: '^_' },
],
'@typescript-eslint/no-use-before-define': 'error',
'@typescript-eslint/restrict-template-expressions': [
'error',
{
allowAny: false,
allowBoolean: false,
allowNullish: false,
allowNumber: true,
allowRegExp: false,
allowNever: false,
},
],

// Eslint
'dot-notation': 'warn',
Expand Down Expand Up @@ -274,6 +263,17 @@ const rulesRequiringTypes = {
'@typescript-eslint/no-unnecessary-type-assertion': 'error',
'@typescript-eslint/prefer-nullish-coalescing': 'warn',
'@typescript-eslint/prefer-optional-chain': 'warn',
'@typescript-eslint/restrict-template-expressions': [
'error',
{
allowAny: false,
allowBoolean: false,
allowNullish: false,
allowNumber: true,
allowRegExp: false,
allowNever: false,
},
],
'@typescript-eslint/switch-exhaustiveness-check': 'error',
} satisfies SharedConfig.RulesRecord

Expand Down

0 comments on commit 81111b2

Please sign in to comment.