This is my tslint.json:
{
"extends": [
"tslint:latest"
],
"rules": {
"no-require-imports": false,
"quotemark": [
true, "single", "avoid-escape"
]
}
}
I thought setting no-require-imports to false will allow me to use require in my code but I'm still getting "require statement not part of an import statement" errors.
How can I turn that rule off?
@mohsen1 that lint failure is from the no-var-requires rule. Try using the verbose formatter to see which rule is triggering each failure. https://github.com/palantir/tslint/blob/24017dc49c64d45c5652798e357997d7faab23fa/src/rules/noVarRequiresRule.ts#L37
That worked. Thanks!
Most helpful comment
@mohsen1 that lint failure is from the no-var-requires rule. Try using the verbose formatter to see which rule is triggering each failure. https://github.com/palantir/tslint/blob/24017dc49c64d45c5652798e357997d7faab23fa/src/rules/noVarRequiresRule.ts#L37