Registry / devops / babel-plugin-streamline

babel-plugin-streamline

JSON →
library2.0.26jsnpmunverified

Babel plugin that enables compile-time transformation of Streamline.js async syntax (callback-, fiber-, and generator-based) within the Babel ecosystem. This package (version 2.0.26, last stable) allows you to combine Streamline's non-blocking control flow with Babel's transpilation pipeline. Key differentiators: integrates Streamline's _ (callback) / fiber / generator modes as Babel plugins, requires matching Babel major version, and is primarily for legacy projects using Streamline.js. Release cadence is low; mainly maintenance updates.

npm install babel-plugin-streamline
INSTALL
IMPORT
SIG · BABEL-PLUGIN-STREA
B
babel-plugin-streamline
devopsjavascriptv2.0.26
Install
Import
Disk
Pass rate
0/ 6
Env Coverage0 / 6
glibc
1822
musl
1822
Install & Compatibility
Where this runs
tested against v? · npm install
Install × environment matrix
Each cell = how many times install + import succeeded across repeated harness runs. Partial = flaky.
glibc = Debian/Ubuntu slim · musl = Alpine Linux
musl
node 18226 runs
build_error
glibc
node 18226 runs
build_error
Code
Verified usage

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

plugin
{ plugins: ["streamline"] }
{ plugins: ["babel-plugin-streamline"] }
Babel plugin name is 'streamline' not full package name
options
{ extra: { streamline: { runtime: 'callbacks' } } }
{ plugins: [["streamline", { runtime: 'callbacks' }]] }
Options are passed via extra.streamline, not plugin array args
use with generators
{ extra: { streamline: { runtime: 'generators' } }, blacklist: ['regenerator'] }
{ extra: { streamline: { runtime: 'generators' } } }
Must blacklist regenerator plugin when using generators runtime

Configures Babel to transform Streamline.js callback-style async code using the callbacks runtime.

// Install: npm install babel-plugin-streamline babel-core // .babelrc { "plugins": ["streamline"], "extra": { "streamline": { "runtime": "callbacks" } } } // Input file (app._js) function delay(ms, callback) { setTimeout(callback, ms); } function test() { console.log('before'); delay(1000, _); console.log('after'); }
Debug
Known issues
breakingbabel-plugin-streamline only works with Babel 5.x and 6.x; not compatible with Babel 7+
fix
Do not use with Babel 7; consider switching to @babel/plugin or alternative async transform.
affects: >=2.0.0
gotchaOptions must be placed under babel's extra object, not as plugin arguments.
fix
Set options via extra.streamline in Babel config.
affects: >=0.0.0
gotchaWhen using 'generators' or 'fibers' runtime, you must blacklist Babel's regenerator plugin to avoid conflicts.
fix
Add 'blacklist': ['regenerator'] to Babel config when runtime is not 'callbacks'.
affects: >=0.0.0
deprecatedPackage is in maintenance mode; no active development; consider migrating away from Streamline.js.
fix
Replace Streamline.js with async/await or other modern async patterns.
affects: >=0.0.0
Errors
Common errors & fixes
ReferenceError: _ is not defined
Missing or incorrect require of streamline runtime (e.g., require('streamline').register())
fix
Add require('streamline').register() at entry point or use runtime option 'callbacks' which auto-includes helpers.
Babel 7: Cannot find module 'babel-plugin-streamline'
babel-plugin-streamline is not compatible with Babel 7; npm install may fail or resolve incorrectly.
fix
Downgrade to Babel 6 or use an alternative async transform (e.g., @babel/plugin-transform-runtime).
TypeError: Cannot read property 'transpile' of undefined
Using plugin array syntax with options instead of extra object.
fix
Move options to extra.streamline in Babel config; do not pass options as second element in plugins array.
Upgrade
Version history
2.0.26latest on npm
Audit
Dependencies
streamline-runtimeoptionalProvides the runtime for Streamline.js callbacks/fibers/generators
babel-coreoptionalRequired peer dependency for Babel plugin interface; version must match Babel 5/6
Agent activity
4 hits · last 30 days
node
4
Resources
babel-plugin-streamline — npm install babel-plugin-streamline · libregistry