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.
@megatherium/sleep
Advanced tools
Returns a Promise that resolves after a given amount of milliseconds.
Returns a Promise that resolves after a given amount of milliseconds.
See the whole documentation or the coverage report.
Install the module:
$ npm install @megatherium/sleep
Use the module:
import sleep from '@megatherium/sleep';
(async() => {
console.log('Waiting 2 seconds...');
await sleep(2000);
console.log('Waited 2 seconds.');
})();
sleep(timeoutInMilliseconds: int): Promise
Returns a Promise that resolves after a given amount of milliseconds.
The following scripts can be executed using npm run
:
build
Builds the module.build-docs
Builds the documentation.build-source
Builds the source code.build-tests
Builds test-cases from jsdoc examples.clear
Clears the module from a previous build.clear-coverage
Clears the coverage reports and caches.clear-docs
Clears the previous documentation build.clear-source
Clears the previous source build.clear-tests
Clears the generated jsdoc example test files.fix
Runs all automated fixes.fix-lint
Automatically fixes linting problems.release
Runs semantic release. Meant to be only executed by the CI, not by human users.test
Executes all tests.test-coverage
Generates coverage reports from the test results using nyc.test-deps
Executes a depcheck.test-e2e
Executes End-to-End-Tests using cucumber.test-integration
Executes integration tests using jest.test-lint
Executes linting tests using eslint.test-unit
Executes unit tests using mocha.update
Checks for dependency updates using renovate.See Contribution Guidelines for more details.
FAQs
Returns a Promise that resolves after a given amount of milliseconds.
The npm package @megatherium/sleep receives a total of 0 weekly downloads. As such, @megatherium/sleep popularity was classified as not popular.
We found that @megatherium/sleep 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’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.