Research
Security News
Malicious npm Packages Inject SSH Backdoors via Typosquatted Libraries
Socket’s threat research team has detected six malicious npm packages typosquatting popular libraries to insert SSH backdoors.
eslint-plugin-typescript-sort-keys
Advanced tools
Sort interface and string enum keys
Inspired by and sourced from eslint/sort-keys
You'll first need to install
yarn add -D eslint typescript @typescript-eslint/parser
Next, install eslint-plugin-typescript-sort-keys
:
yarn add -D eslint-plugin-typescript-sort-keys
Note: If you installed ESLint globally then you must also install eslint-plugin-typescript-sort-keys
globally.
Specify the parser for typescript files in your .eslintrc
configuration file:
{
"parser": "@typescript-eslint/parser"
}
Add typescript-sort-keys
to the plugins section. You can omit the eslint-plugin-
prefix:
{
"plugins": ["typescript-sort-keys"]
}
Then configure the rules you want to use under the rules section.
{
"rules": {
"typescript-sort-keys/interface": "error",
"typescript-sort-keys/string-enum": "error"
}
}
Or enable all rules with defaults
{
"extends": ["plugin:typescript-sort-keys/recommended"]
}
Key: :heavy_check_mark: = recommended, :wrench: = fixable
Name | Description | :heavy_check_mark: | :wrench: |
---|---|---|---|
typescript-sort-keys/interface | require interface keys to be sorted | :heavy_check_mark: | :wrench: |
typescript-sort-keys/string-enum | require string enum members to be sorted | :heavy_check_mark: | :wrench: |
[3.3.0] - 2024-10-05
FAQs
Sort interface and string enum keys
The npm package eslint-plugin-typescript-sort-keys receives a total of 337,839 weekly downloads. As such, eslint-plugin-typescript-sort-keys popularity was classified as popular.
We found that eslint-plugin-typescript-sort-keys 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.
Research
Security News
Socket’s threat research team has detected six malicious npm packages typosquatting popular libraries to insert SSH backdoors.
Security News
MITRE's 2024 CWE Top 25 highlights critical software vulnerabilities like XSS, SQL Injection, and CSRF, reflecting shifts due to a refined ranking methodology.
Security News
In this segment of the Risky Business podcast, Feross Aboukhadijeh and Patrick Gray discuss the challenges of tracking malware discovered in open source softare.