parcel: Unknown plugin "transform-es2015-arrow-functions" with basic project
Bug Report π
I created a minimal project (following https://parceljs.org/getting_started.html. The only difference is that I include the package βwsβ in package.json). Launching parcel via parcel index.html causes the error you can see below.
π Configuration (.babelrc, package.json, cli command)
package.json
{
"name": "dashboard",
"version": "1.0.0",
"description": "",
"main": "index.js",
"dependencies": {
"ws": "^3.3.3"
},
"devDependencies": {},
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1"
},
"author": "",
"license": "ISC"
}
π€ Expected Behavior
Parcel bundles up the project without any problem.
π― Current Behavior
β³ Building...
Server running at http://localhost:1234
π¨ /usr/local/lib/node_modules/parcel-bundler/node_modules/browserify-zlib/lib/binding.js: Unknown plugin "transform-es2015-arrow-functions" specified in "/usr/local/lib/node_modules/parcel-bundler/node_modules/browserify-zlib/package.json" at 0, attempted to resolve relative to "/usr/local/lib/node_modules/parcel-bundler/node_modules/browseri at /usr/local/lib/node_modules/parcel-bundler/node_modules/babel-core/lib/transformation/file/options/option-manager.js:180:17
at Array.map (<anonymous>)
at Function.normalisePlugins (/usr/local/lib/node_modules/parcel-bundler/node_modules/babel-core/lib/transformation/file/options/option-manager.js:158:20)
at OptionManager.mergeOptions (/usr/local/lib/node_modules/parcel-bundler/node_modules/babel-core/lib/transformation/file/options/option-manager.js:234:36)
at OptionManager.init (/usr/local/lib/node_modules/parcel-bundler/node_modules/babel-core/lib/transformation/file/options/option-manager.js:368:12)
at File.initOptions (/usr/local/lib/node_modules/parcel-bundler/node_modules/babel-core/lib/transformation/file/index.js:212:65)
at new File (/usr/local/lib/node_modules/parcel-bundler/node_modules/babel-core/lib/transformation/file/index.js:135:24)
at JSAsset.parse (/usr/local/lib/node_modules/parcel-bundler/src/assets/JSAsset.js:55:20)
at JSAsset.parseIfNeeded (/usr/local/lib/node_modules/parcel-bundler/src/Asset.js:46:29)
at <anonymous>
π Possible Solution
No idea. The project is too small for anything to cause this error.
π¦ Context
Just trying out parcel to bundle the simplest project.
π Your Environment
| Software | Version(s) |
|---|---|
| Parcel | 1.2.0 |
| Node | v9.3.0 |
| npm/Yarn | npm 5.6.0 |
| Operating System | OSX 10.13.2 |
About this issue
- Original URL
- State: closed
- Created 7 years ago
- Comments: 21 (8 by maintainers)
yarn add babel-plugin-transform-es2015-arrow-functions --devORnpm install babel-plugin-transform-es2015-arrow-functions --save-devShould fix your issuePlease close the issue if this resolved the bug
@DeMoorJasper @sergi im having the same issue⦠same situation
By investigating for a while I have myself a workaround. This might help anybody who encountered the same problem.
Instead of using parcel globally, I install it locally by
npm install --save-dev parcel-bundler. Then I add a npm script likeAlso I need preset-es2015 or I will get another issue.
Then use
npm startfor bundling and everything works.This is probably #13.
@DeMoorJasper quick repo⦠https://github.com/cristiandley/parcel-example
If someone could provide a basic project with this bug than i could confirm if its a bug or how to actually fix this
Sent with GitHawk