Security News
Fluent Assertions Faces Backlash After Abandoning Open Source Licensing
Fluent Assertions is facing backlash after dropping the Apache license for a commercial model, leaving users blindsided and questioning contributor rights.
eslint-plugin-depend
Advanced tools
An ESLint plugin to suggest optimized dependencies, native alternatives and more
This is an ESLint plugin to help suggest alternatives to various dependencies.
Primarily, it will help detect dependency tree bloat and redundant polyfills.
npm i -D eslint-plugin-depend
If you're using the new flat config files, add to your eslint.config.js
:
import * as depend from 'eslint-plugin-depend';
export default [
depend.configs['flat/recommended'],
// or if you want to specify `files`, or other options
{
...depend.configs['flat/recommended'],
files: ['test/**/*.js']
}
];
For older legacy projects, add to your .eslintrc.json
:
{
"extends": [
"plugin:depend/recommended"
]
}
package.json
Some rules (e.g. ban-dependencies
) can be used against your package.json
.
You can achieve this by using jsonc-eslint-parser
.
For example, in your .eslintrc.json
:
{
"overrides": [
{
"files": ["package.json"],
"parser": "jsonc-eslint-parser",
"plugins": ["depend"],
"rules": {
"depend/ban-dependencies": "error"
}
}
]
}
Read more at the
jsonc-eslint-parser
docs.
MIT
FAQs
An ESLint plugin to suggest optimized dependencies, native alternatives and more
We found that eslint-plugin-depend demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 0 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Fluent Assertions is facing backlash after dropping the Apache license for a commercial model, leaving users blindsided and questioning contributor rights.
Research
Security News
Socket researchers uncover the risks of a malicious Python package targeting Discord developers.
Security News
The UK is proposing a bold ban on ransomware payments by public entities to disrupt cybercrime, protect critical services, and lead global cybersecurity efforts.