eslint-plugin-typescript-filenames
Adds eslint rules to ensure consistent filenames for your javascript files.
Please note: This plugin will only lint the filenames of the .js
, .jsx
files you are linting with eslint. It will ignore other files that are not linted with eslint.
Enabling the plugin
This plugin requires a version of eslint>=5.x
to be installed as a peer dependency.
Modify your .eslintrc
file to load the plugin and enable the rules you want to use.
Rules
Don't allow .js files (no-js-extensions)
When enabling this rule, the plugin will throw an error advising you to use .ts
.
Don't allow .jsx files (no-jsx-extensions)
When enabling this rule, the plugin will throw an error advising you to use .tsx
.