Registry / devops / rollup-plugin-crypto-key

rollup-plugin-crypto-key

JSON →
library0.5.0jsnpmunverified

A Rollup/Vite plugin for managing cryptographic keys as virtual modules. Version 0.5.0 is the latest and only stable release. It allows injecting keys (e.g., RSA, ECDSA) at build time via virtual imports. Ships TypeScript types. Differentiates from dotenv or env plugins by focusing on key material and supporting multiple formats. Release cadence is unknown. Minimal dependencies.

npm install rollup-plugin-crypto-key
INSTALL
IMPORT
SIG · ROLLUP-PLUGIN-CRYP
R
rollup-plugin-crypto-key
devopsjavascriptv0.5.0
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

default
import rollupPluginCryptoKey from 'rollup-plugin-crypto-key'
const rollupPluginCryptoKey = require('rollup-plugin-crypto-key')
ESM-only; no CommonJS support.
rollupPluginCryptoKey
import rollupPluginCryptoKey from 'rollup-plugin-crypto-key'
import { rollupPluginCryptoKey } from 'rollup-plugin-crypto-key'
Default export, not named.
VitePlugin
import { VitePlugin } from 'rollup-plugin-crypto-key'
import VitePlugin from 'rollup-plugin-crypto-key'
Named export for Vite integration.

Basic Rollup configuration using the crypto key plugin as default export.

import rollupPluginCryptoKey from 'rollup-plugin-crypto-key'; export default { input: 'src/index.js', output: { file: 'dist/bundle.js', format: 'es' }, plugins: [ rollupPluginCryptoKey() ] };
Debug
Known issues
gotchaPlugin requires Rollup >=3 or Vite >=4.
fix
Upgrade Rollup or Vite to compatible version.
affects: >=0.0.0
gotchaKeys are injected as virtual modules; ensure no conflicts with other virtual module plugins.
fix
Configure virtual module ID prefix via options.
affects: >=0.0.0
Errors
Common errors & fixes
Error: 'default' is not exported by rollup-plugin-crypto-key
Using CommonJS require() in an ESM-only environment.
fix
Use ESM import syntax: import rollupPluginCryptoKey from 'rollup-plugin-crypto-key'
TypeError: rollupPluginCryptoKey is not a function
Misplaced parentheses or incorrect import (named instead of default).
fix
Ensure default import: import rollupPluginCryptoKey from 'rollup-plugin-crypto-key'
Upgrade
Version history
0.5.0latest on npm
Audit
Dependencies

No dependency data recorded yet.

Agent activity
4 hits · last 30 days
node
4
Resources
rollup-plugin-crypto-key — npm install rollup-plugin-crypto-key · libregistry