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.
@alice-health/ky-hooks-change-case
Advanced tools
Allow modifications cases on requests and responses of the objects during the ky request
Allow modifications cases on requests and responses of the objects during the ky request
$ npm install @alice-health/ky-hooks-change-case
import ky from "ky";
import {
requestToSnakeCase,
responseToCamelCase,
} from "@alice-health/ky-hooks-change-case";
ky.post(`${server.url}/path`, {
json: { fooBar: true },
hooks: {
beforeRequest: [requestToSnakeCase],
afterResponse: [responseToCamelCase],
},
});
In the example above, the requestToSnakeCase
method will convert the resquest body from {fooBar: true}
to {foo_bar: true}
and the response from {response_body: false}
to {responseBody: false}
. This way, the frontend and the backend API can each define their independent style guide.
Convert the request body keys objects to snake_case
.
Convert the request body keys objects to camelCase
.
Convert the request body keys objects to kebab-case
.
Convert the response body keys objects to snake_case
.
Convert the response body keys objects to camelCase
.
Convert the response body keys objects to kebab-case
.
The latest version of Chrome, Firefox, and Safari.
ky 🌳 Tiny & elegant HTTP client based on window.fetch
FAQs
Allow modifications cases on requests and responses of the objects during the ky request
The npm package @alice-health/ky-hooks-change-case receives a total of 406 weekly downloads. As such, @alice-health/ky-hooks-change-case popularity was classified as not popular.
We found that @alice-health/ky-hooks-change-case demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 5 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.