
Security News
Attackers Are Hunting High-Impact Node.js Maintainers in a Coordinated Social Engineering Campaign
Multiple high-impact npm maintainers confirm they have been targeted in the same social engineering campaign that compromised Axios.
esbuild-plugin-cache
Advanced tools
The plugin allows to use http/https imports without installing npm packages on node_modules.
It also allows to use import-maps .
It can provide a feature similar to Snowpack 3.0, the new Streaming NPM Imports, which allows to skip the NPM install and node_modules.
//index.js
import React from 'https://cdn.skypack.dev/react@17.0.1'
console.log(React.version)
//build.js
import esbuild from 'esbuild'
import { cache } from 'esbuild-plugin-cache'
esbuild
.build({
entryPoints: ['index.js'],
bundle: true,
outfile: 'bundle.js',
plugins: [cache()],
})
.catch(() => process.exit(1))
config: {importmap: {imports:{[key: string]: string}}, directory: string}
importmap: Import-map object. Default: {}
directory: Path or name for the directory of the cache. Default to Deno cache directory. Optionally the cache directory can be defined with DENO_DIR env variable: process.env.DENO_DIR = 'cache'.
importmap//index.js
import React from 'react'
console.log(React.version)
//build.js
import esbuild from 'esbuild'
import { cache } from 'esbuild-plugin-cache'
const importmap = {
imports: {
react: 'https://cdn.skypack.dev/react@17.0.1',
},
}
esbuild
.build({
entryPoints: ['index.js'],
bundle: true,
outfile: 'bundle.js',
plugins: [cache({ importmap, directory: './cache' })],
})
.catch(() => process.exit(1))
FAQs
Esbuid plugin to use cache for http/https
The npm package esbuild-plugin-cache receives a total of 765 weekly downloads. As such, esbuild-plugin-cache popularity was classified as not popular.
We found that esbuild-plugin-cache 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
Multiple high-impact npm maintainers confirm they have been targeted in the same social engineering campaign that compromised Axios.

Security News
Axios compromise traced to social engineering, showing how attacks on maintainers can bypass controls and expose the broader software supply chain.

Security News
Node.js has paused its bug bounty program after funding ended, removing payouts for vulnerability reports but keeping its security process unchanged.