-
-
Notifications
You must be signed in to change notification settings - Fork 2.8k
Closed
Labels
bugSomething isn't workingSomething isn't workinggood first issueGood for newcomersGood for newcomerspackage: eslint-pluginIssues related to @typescript-eslint/eslint-pluginIssues related to @typescript-eslint/eslint-plugin
Description
Repro
{
"rules": {
"@typescript-eslint/quotes": [
"error",
"backtick"
]
}
}
import moment = require('moment');
Expected Result
Should not produce any error
Actual Result
produces an error, and fix will cause typescript compilation to fail as back ticks are not valid in a require statement.
Additional info
When you need to import from old modules that use the following syntax
export = ...
You must use
import moment = require('moment');
to import them, and the rule alerts on those.
Versions
package | version |
---|---|
@typescript-eslint/eslint-plugin |
^2.24.0 |
@typescript-eslint/parser |
^2.24.0 |
TypeScript |
^3.8.3 |
ESLint |
^6.8.0 |
node |
v10.19.0 |
npm |
6.13.4 |
moment |
^2.24.0 |
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't workinggood first issueGood for newcomersGood for newcomerspackage: eslint-pluginIssues related to @typescript-eslint/eslint-pluginIssues related to @typescript-eslint/eslint-plugin