You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In the past, this tool didn't respect the TSLint configuration of `ban-types`,
it means even if TSLint specified `ban-types` with the argument, generated
ESLint configuration doesn't contain the detailed configuration of that.
For example, when the TSLint configuration is like the following:
```
{
"rules": {
"ban-types": [true,
["Object", "Use {} instead."],
]
}
}
```
then, older tool generates the following ESLint configuration:
```
"rules": {
"@typescript-eslint/ban-types": "error"
}
```
According to the official documentation, probably this generated result
doesn't make sense because each rule requires the type name (and the message).
https://github.com/typescript-eslint/typescript-eslint/blob/f3160b471f8247e157555b6cf5b40a1f6ccdc233/packages/eslint-plugin/docs/rules/ban-types.md
So this commit makes the generated ESLint configuration to be suitable to the certainly
working configuration, like so:
```
"rules": {
"@typescript-eslint/ban-types": [
"error",
{
"types": {
"Object": {
"message": "Use {} instead."
}
}
}
]
}
```
See also: https://palantir.github.io/tslint/rules/ban-types/
Related ticket: #352
0 commit comments