{"id":19337,"library":"babel-preset-stage-0","title":"babel-preset-stage-0","description":"Babel preset that enables all stage 0 (strawman) JavaScript proposal plugins. Version 6.24.1 is the latest stable release; this package is part of Babel 6 and has been deprecated in favor of individual proposal plugins or @babel/preset-env with targets. It includes plugins for syntactic proposals like do-expressions, pipeline operator, and throw expressions. No longer maintained; users should migrate to Babel 7/8 and use specific plugins.","status":"deprecated","version":"6.24.1","language":"javascript","source_language":"en","source_url":"https://github.com/babel/babel/tree/master/packages/babel-preset-stage-0","tags":["javascript"],"install":[{"cmd":"npm install babel-preset-stage-0","lang":"bash","label":"npm"},{"cmd":"yarn add babel-preset-stage-0","lang":"bash","label":"yarn"},{"cmd":"pnpm add babel-preset-stage-0","lang":"bash","label":"pnpm"}],"dependencies":[{"reason":"stage-0 includes stage-1, stage-2, and stage-3 presets","package":"babel-preset-stage-1","optional":false}],"imports":[{"note":"CommonJS require is used; ESM import not supported.","wrong":"import presets from 'babel-preset-stage-0'","symbol":"preset-stage-0","correct":"require('babel-preset-stage-0')"},{"note":"Preset names can be shorthand; no need for full package name in .babelrc.","wrong":"module.exports = { presets: ['babel-preset-stage-0'] }","symbol":"default","correct":"module.exports = { presets: ['stage-0'] }"},{"note":"Passing preset name as string is idiomatic.","wrong":"babel.transform(code, { presets: [require('babel-preset-stage-0')] })","symbol":"transform","correct":"babel.transform(code, { presets: ['stage-0'] })"}],"quickstart":{"code":"// Install: npm install --save-dev babel-preset-stage-0\n// .babelrc\n{\n  \"presets\": [\"stage-0\"]\n}\n\n// Example JS with stage-0 features\n// Pipeline operator: 2 |> double |> square\nconst double = x => x * 2;\nconst square = x => x * x;\nconst result = 2 |> double |> square;\nconsole.log(result); // 16","lang":"javascript","description":"Shows how to install and configure the stage-0 preset, then use a pipeline operator (stage-0 proposal)."},"warnings":[{"fix":"Use @babel/preset-env with specific targets or individual plugins.","message":"babel-preset-stage-0 is deprecated in Babel 7+","severity":"deprecated","affected_versions":">=7.0.0"},{"fix":"Migrate to @babel/preset-env and explicit plugin configuration.","message":"Stage presets are removed in Babel 8","severity":"breaking","affected_versions":">=8.0.0"},{"fix":"Pin exact Babel version and update proposals carefully.","message":"Including stage-0 enables unstable proposals that may change or be removed","severity":"gotcha","affected_versions":"all"},{"fix":"Remove stage presets and use individual plugins for needed proposals.","message":"Stage presets depend on deprecated babel-preset-stage-1, -2, -3","severity":"deprecated","affected_versions":"all"}],"env_vars":null,"last_verified":"2026-04-25T00:00:00.000Z","next_check":"2026-07-24T00:00:00.000Z","problems":[{"fix":"npm install --save-dev babel-preset-stage-0@6.24.1","cause":"Package not installed or version mismatch","error":"Error: Cannot find module 'babel-preset-stage-0'"},{"fix":"Upgrade to @babel/preset-stage-0 or use Babel 6","cause":"Using an older Babel 6 preset with Babel 7","error":"Error: Plugin/Preset files are not allowed to export objects, only functions."},{"fix":"Migrate to @babel/preset-env and individual plugins","cause":"Babel 7 dropped support for stage presets","error":"TypeError: (intermediate value) is not a function"}],"ecosystem":"npm","meta_description":null,"install_score":null,"install_tag":null,"quickstart_score":null,"quickstart_tag":null}