Open chkpnt opened 2 years ago
According to 3.4.1.1.1 File extensions in import paths, "the .js file extension is not optional in import paths and must always be included."
I guess this rule shouldn't be limited to '.js' but to all imported modules. Nevertheless, eslint-config-google should be able to enforce 3.4.1.1.1.
eslint-config-google
Currently, I'm using import/extension from eslint-plugin-import with this config:
import/extension
eslint-plugin-import
rules: { // ... "import/extensions": ["error", "always"], // ... }
In order to enforce 3.4.1.1.1 one-to-one, "import/extensions": ["error", { js: "always" }] is the corresponding configuration.
"import/extensions": ["error", { js: "always" }]
I suggest to include (copy?) import/extension into eslint-config-google.
According to 3.4.1.1.1 File extensions in import paths, "the .js file extension is not optional in import paths and must always be included."
I guess this rule shouldn't be limited to '.js' but to all imported modules. Nevertheless,
eslint-config-google
should be able to enforce 3.4.1.1.1.Currently, I'm using
import/extension
fromeslint-plugin-import
with this config:In order to enforce 3.4.1.1.1 one-to-one,
"import/extensions": ["error", { js: "always" }]
is the corresponding configuration.I suggest to include (copy?)
import/extension
intoeslint-config-google
.