Make sure no 👻 phantom dependencies are used in your project.
You'll first need to install ESLint:
npm i eslint --save-dev
Next, install eslint-plugin-phantom-dependencies
:
npm install eslint-plugin-phantom-dependencies --save-dev
On your .eslintrc
file extend the plugin's recommended configuration:
{
"extends": ["plugin:phantom-dependencies/recommended"]
}
If you want to use your own configuration, you can do so by adding the plugin to the plugins section of your .eslintrc
configuration file. You can omit the eslint-plugin-
prefix:
{
"plugins": ["phantom-dependencies"]
}
Then configure the rules you want to use under the rules section.
{
"rules": {
"phantom-dependencies/no-phantom-dependencies": "error"
}
}
💼 Configurations enabled in.
✅ Set in the recommended
configuration.
Name | Description | 💼 |
---|---|---|
no-phantom-dependencies | Make sure no phantom dependencies are used in your project. | ✅ |