
Research
/Security News
Weaponizing Discord for Command and Control Across npm, PyPI, and RubyGems.org
Socket researchers uncover how threat actors weaponize Discord across the npm, PyPI, and RubyGems ecosystems to exfiltrate sensitive data.
JoFetch is a JavaScript tool that provides enhanced fetch functionality.
There are a lot of functions in this tool, such as simple or integration version. Of course, all functions are successfully tested by Jest. By the way, hope this fetch function return any data jo(just) like how we call it.
import joFetch from 'jo-fetch'
let doc = await joFetch(
'https://www.google.com',
{ method: 'GET' },
{
loadingTime: 10000,
retryTimes: 5,
retryDelay: 1000,
returnType: 'html',
}
)
import { fetchDocument } from 'jo-fetch'
let doc = await fetchDocument(
'https://www.google.com',
{ method: 'GET' }
)
npm install jo-fetch
joFetch(url, parem, config)
The following are the attributes in the parameter config.
Attribute | Type | Description |
---|---|---|
loadingTime | number | Define the loading time for this fetch. If the fetch time exceeds this value, this fetch fails and an error is thrown. |
retryTimes | number | Define the number of times to retry to fetch it again when this fetch fails. |
retryDelay | number | Define the delay before each retry. |
returnType | string | Specify the type of returned data. |
The parameters, url and param, are same as window.fetch.
Function | Return Type | Description |
---|---|---|
fetchJSON(url, param) | Promise | Return the result in json form after fetching. |
fetchDocument(url, param) | Promise | Return the result as a document after fetching. |
fetchInTime(url, param, time) | Promise | Return the result within a limit time. if not, this fetch fails and an error is thrown. |
fetchAutoRetry(url, param, times, delay) | Promise | Return the result, and if the fetch fails, automatically retry to fetch within a limited number of times. |
JoFetch is MIT licensed.
FAQs
JoFetch is a JavaScript tool that provides enhanced fetch functionality.
The npm package jo-fetch receives a total of 0 weekly downloads. As such, jo-fetch popularity was classified as not popular.
We found that jo-fetch demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer 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 researchers uncover how threat actors weaponize Discord across the npm, PyPI, and RubyGems ecosystems to exfiltrate sensitive data.
Security News
Socket now integrates with Bun 1.3’s Security Scanner API to block risky packages at install time and enforce your organization’s policies in local dev and CI.
Research
The Socket Threat Research Team is tracking weekly intrusions into the npm registry that follow a repeatable adversarial playbook used by North Korean state-sponsored actors.