ES6 Module Transpiler Brunch Plugin
raw JSON → 0.0.6 verified Fri May 01 auth: no javascript deprecated
A Brunch plugin that integrates the es6-module-transpiler, an experimental compiler for writing JavaScript using a subset of ES6 module syntax and compiling it into AMD, CommonJS, or globals. This package is at version 0.0.6 and appears to be an early-stage project with minimal updates. It is designed for use with Brunch, but given its low version and experimental nature, it should be considered unstable. The plugin wraps the es6-module-transpiler (no longer actively maintained) and does not support modern ES modules. Use with caution.
Common errors
error Error: Cannot find module 'es6-module-transpiler' ↓
cause es6-module-transpiler is not installed or missing from node_modules.
fix
Run
npm install es6-module-transpiler --save-dev as it is a peer dependency. error Error: Plugin es6-module-transpiler-brunch failed: ... ↓
cause Configuration options may be invalid or unsupported.
fix
Check brunch-config for valid es6modules options (target: 'amd', 'cjs', or 'globals').
error TypeError: Cannot read property 'transpile' of undefined ↓
cause The plugin cannot find the es6-module-transpiler instance.
fix
Ensure es6-module-transpiler is installed and is version compatible with the plugin.
Warnings
deprecated The es6-module-transpiler is no longer actively maintained and does not support modern ES module syntax (e.g., export default, import()). Consider using Babel or TypeScript instead. ↓
fix Replace with a modern transpiler like Babel (babel-brunch) or TypeScript (ts-brunch).
breaking Version 0.0.6 may have breaking changes from earlier 0.0.x releases due to lack of stable API. No changelog provided. ↓
fix Pin to specific version and test thoroughly.
gotcha Plugin is experimental and may produce incorrect output for advanced ES6 module patterns like default exports or re-exports. ↓
fix Test compiled output thoroughly or migrate to Babel.
deprecated Brunch itself has moved on; consider using a more modern build tool. ↓
fix Evaluate alternatives like Webpack, Rollup, or Vite.
Install
npm install es6-module-transpiler-brunch yarn add es6-module-transpiler-brunch pnpm add es6-module-transpiler-brunch Imports
- default wrong
const plugin = require('es6-module-transpiler-brunch')correctimport 'es6-module-transpiler-brunch' - Register as Brunch plugin wrong
const Es6Transpiler = require('es6-module-transpiler-brunch')correctIn brunch-config: plugins: {es6modules: { /* options */ }} - Configuration object wrong
import { transpiler } from 'es6-module-transpiler-brunch'correctexport default { plugins: { es6modules: { target: 'amd' } } }
Quickstart
// In brunch-config.js or package.json:
module.exports = {
plugins: {
es6modules: {
target: 'amd' // or 'cjs', 'globals'
}
}
};