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
Also, current way overrides parserOptions.parser which it would ideally not do for all file types since other might want to use babel-parser rather (although I haven't found specific issues with current solution).
The text was updated successfully, but these errors were encountered:
Also, the current use of typescript plugin is rather minimal.
Only the typescript parser from typescript plugin is enabled but otherwise, no rules are utilized (besides one). It would make sense to at least extend the base config from that plugin. That would also take care of setting the parserOptions so that it wouldn't have to be done in this package itself.
EDIT: Actually extending base configuration from typescript plugin wouldn't work as that would override the parser and break vue plugin. So rules would need to be copied over and scoped to .ts/.tsx extensions instead.
And typescript config doesn't even follow base Nuxt rules like no semi and single quotes (amongst others). Is that on purpose to diverge from JS/Vue style used in base config?
In:
https://github.com/nuxt/eslint-config/blob/dc55bbf218c8627d3c4ef73656a32730dd2a9d3c/packages/eslint-config-typescript/index.js#L1-L12
all typescript-specific settings should be in an override block and scoped to
*.ts
extension:One of the many reasons why it should be so is that when enabling some typescript rules, like
@typescript-eslint/no-unused-vars
, you are supposed to disable eslint's ownno-unused-vars
rule (see https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/no-unused-vars.md#options) and you don't want to do that in general, only for *.ts.Also, current way overrides
parserOptions.parser
which it would ideally not do for all file types since other might want to usebabel-parser
rather (although I haven't found specific issues with current solution).The text was updated successfully, but these errors were encountered: