Skip to content

Commit

Permalink
Add @typescript-eslint/no-wrapper-object-types rule
Browse files Browse the repository at this point in the history
  • Loading branch information
sindresorhus committed Jul 23, 2024
1 parent ecc1c11 commit 69b266f
Showing 1 changed file with 1 addition and 24 deletions.
25 changes: 1 addition & 24 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -127,30 +127,6 @@ module.exports = {
{
extendDefaults: false,
types: {
String: {
message: 'Use `string` instead.',
fixWith: 'string'
},
Number: {
message: 'Use `number` instead.',
fixWith: 'number'
},
Boolean: {
message: 'Use `boolean` instead.',
fixWith: 'boolean'
},
Symbol: {
message: 'Use `symbol` instead.',
fixWith: 'symbol'
},
BigInt: {
message: 'Use `bigint` instead.',
fixWith: 'bigint'
},
Object: {
message: 'The `Object` type is mostly the same as `unknown`. You probably want `Record<string, unknown>` instead. See https://github.com/typescript-eslint/typescript-eslint/pull/848',
fixWith: 'Record<string, unknown>'
},
'{}': {
message: 'The `{}` type is mostly the same as `unknown`. You probably want `Record<string, unknown>` instead.',
fixWith: 'Record<string, unknown>'
Expand Down Expand Up @@ -581,6 +557,7 @@ module.exports = {
}
],
'@typescript-eslint/no-var-requires': 'error',
'@typescript-eslint/no-wrapper-object-types': 'error',
'@typescript-eslint/non-nullable-type-assertion-style': 'error',
'@typescript-eslint/parameter-properties': [
'error',
Expand Down

0 comments on commit 69b266f

Please sign in to comment.