{"id":22981,"library":"wepy-compiler-babel","title":"wepy-compiler-babel","description":"Babel compiler plugin for the WePY framework (v1.5.3). This package integrates Babel into WePY's build pipeline, allowing ES2015+ syntax transpilation for WePY projects. It is specifically designed for WePY 1.x and offers configuration via `wepy.config.js`. Unlike generic Babel setups, this plugin seamlessly works with WePY's compilation system. Release cadence is low; the package has been stable with infrequent updates. Key differentiator: tailored for WePY's compiler lifecycle hooks.","status":"maintenance","version":"1.5.3","language":"javascript","source_language":"en","source_url":null,"tags":["javascript","babel"],"install":[{"cmd":"npm install wepy-compiler-babel","lang":"bash","label":"npm"},{"cmd":"yarn add wepy-compiler-babel","lang":"bash","label":"yarn"},{"cmd":"pnpm add wepy-compiler-babel","lang":"bash","label":"pnpm"}],"dependencies":[],"imports":[{"note":"Not imported in source code; configured as a compiler plugin in wepy.config.js","wrong":"import wepyCompilerBabel from 'wepy-compiler-babel'","symbol":"wepy-compiler-babel","correct":"// In wepy.config.js: module.exports = { compilers: { babel: {} } }"}],"quickstart":{"code":"// Install: npm install wepy-compiler-babel --save-dev\n// wepy.config.js\nmodule.exports = {\n  compilers: {\n    babel: {\n      presets: ['es2015', 'stage-1'],\n      plugins: [\n        'transform-export-extensions',\n        'syntax-export-extensions',\n        'transform-runtime'\n      ]\n    }\n  }\n};","lang":"javascript","description":"Configures the babel compiler in a WePY project with ES2015 and Stage-1 presets plus transform plugins."},"warnings":[{"fix":"Use @babel/preset-env and @babel/plugin-transform-runtime, and update wepy-compiler-babel if compatible.","message":"Babel presets 'es2015', 'stage-1' are deprecated in Babel 7+","severity":"deprecated","affected_versions":">=1.0.0"},{"fix":"For WePY 2.x, use wepy-compiler-babel version that supports @wepy/cli or use built-in babel support.","message":"This package only works with WePY 1.x; not compatible with WePY 2.x (wepy-cli v2)","severity":"gotcha","affected_versions":">=1.0.0"},{"fix":"Upgrade Node.js to version 6 or later.","message":"Requires Node.js 6+ due to Babel peer dependencies","severity":"breaking","affected_versions":">=1.0.0"}],"env_vars":null,"last_verified":"2026-04-27T00:00:00.000Z","next_check":"2026-07-26T00:00:00.000Z","problems":[{"fix":"npm install babel-core --save-dev","cause":"Missing Babel core dependency (peer dependency not installed)","error":"Error: Cannot find module 'babel-core'"},{"fix":"Use Babel 6 presets (e.g., 'es2015', 'stage-1') or upgrade to wepy-compiler-babel with Babel 7 support.","cause":"Using a Babel 7 preset (e.g., @babel/preset-env) with Babel 6 core","error":"Error: Plugin/Preset files are not allowed to export objects, only functions."}],"ecosystem":"npm","meta_description":null,"install_score":null,"install_tag":null,"quickstart_score":null,"quickstart_tag":null}