Security News
pnpm 10.0.0 Blocks Lifecycle Scripts by Default
pnpm 10 blocks lifecycle scripts by default to improve security, addressing supply chain attack risks but sparking debate over compatibility and workflow changes.
@esm2cjs/cacheable-lookup
Advanced tools
A cacheable dns.lookup(…) that respects TTL. This is a fork of szmarczak/cacheable-lookup, but with CommonJS support.
This is a fork of https://github.com/szmarczak/cacheable-lookup, but automatically patched to support ESM and CommonJS, unlike the original repository.
You can use an npm alias to install this package under the original name:
npm i @szmarczak/cacheable-lookup@npm:@esm2cjs/cacheable-lookup
// package.json
"dependencies": {
"@szmarczak/cacheable-lookup": "npm:@esm2cjs/cacheable-lookup"
}
but npm
might dedupe this incorrectly when other packages depend on the replaced package. If you can, prefer using the scoped package directly:
npm i @esm2cjs/cacheable-lookup
// package.json
"dependencies": {
"@esm2cjs/cacheable-lookup": "^ver.si.on"
}
// Using ESM import syntax
import CacheableLookup from "@esm2cjs/cacheable-lookup";
// Using CommonJS require()
const CacheableLookup = require("@esm2cjs/cacheable-lookup").default;
Note: Because the original module uses
export default
, you need to append.default
to therequire()
call.
For more details, please see the original repository.
To support my efforts in maintaining the ESM/CommonJS hybrid, please sponsor here.
To support the original author of the module, please sponsor here.
FAQs
A cacheable dns.lookup(…) that respects TTL. This is a fork of szmarczak/cacheable-lookup, but with CommonJS support.
The npm package @esm2cjs/cacheable-lookup receives a total of 8,394 weekly downloads. As such, @esm2cjs/cacheable-lookup popularity was classified as popular.
We found that @esm2cjs/cacheable-lookup 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.
Security News
pnpm 10 blocks lifecycle scripts by default to improve security, addressing supply chain attack risks but sparking debate over compatibility and workflow changes.
Product
Socket now supports uv.lock files to ensure consistent, secure dependency resolution for Python projects and enhance supply chain security.
Research
Security News
Socket researchers have discovered multiple malicious npm packages targeting Solana private keys, abusing Gmail to exfiltrate the data and drain Solana wallets.