Vue-loader: Vue-loader wants babel-runtime@^5.8.0

Created on 8 Dec 2015  ·  15Comments  ·  Source: vuejs/vue-loader

But I've used babel-runtime@6 in my project.

preview

Most helpful comment

FYI: finally merged https://github.com/babel/babel/pull/3438 in 6.8.0

All 15 comments

Well, have to downgrade to 5.8.0 instead.

It still works even after throwing this error. It's because 5.x.x -> 6.x.x is a major version from vue-loaders specified peerDeps afaik.

@billcolumbia why vue-loader does not upgrade to 6.x.x?

Not sure. @yyx990803 will probably update the dependencies as things like this pop up. Would likely need to test to make sure the new versions don't break others deps or this package first.

This is an intended downgrade. Babel runtime 6.x has a few unresolved bugs that makes it impossible to use typeof and a few other features. Also, because all babel plugins still depend on runtime 5.x, using 6.x at top level causes every single plugin to download a separate copy of 5.x, which ends up with 100Mb+ wasted disk space and a slower startup time.

I've already talked with Babel core team members about this and will upgrade to runtime 6.x when these issues are resolved.

Nice. Thanks for the info - just downgraded! @yyx990803!

Good point, Evan!

I don't know if this will be read or not (issue being closed n' all), but Babel version change should be reflected on the 'README.md' with minor explanation why Vue-loader is not using Babel 6 (for now)

@moe-szyslak It is still using Babel 6, the downgrade is only for the babel-runtime peer dependency. Usage is the same.

ok, got it

While I have this _stage_, I would like to say thank you for all your hard work!

Hey @yyx990803 was just wondering if there's any news on this? It doesn't seem to be a big deal, I'm just curious whether those issues you mentioned have been resolved, and if not then what's holding them up? Maybe there are some issues you could point folks to so whoever has free time can help out?

@taoeffect the core issue is that all official babel 6 plugins still rely on [email protected] as a dependency because they were compiled using babel 5. It seems they are indeed trying to move to self-hosting with babel 6 though:

FYI: finally merged https://github.com/babel/babel/pull/3438 in 6.8.0

Came here from this page: http://vuejs.github.io/vue-loader/start/tutorial.html
As far as I can see, vue-loader now requires babel-runtime 6?

What a coincidence, I arrived from the very same page as @duebbert, and I get npm WARN EPEERINVALID [email protected] requires a peer of babel-runtime@^6.0.0 but none was installed.

If I do npm install babel-runtime, I get

npm WARN install Couldn't install optional dependency: Unsupported
myproj@ C:\path\to\vue_webpack\myproj
└── UNMET PEER DEPENDENCY [email protected]

I am a bit confused now about which version I should have.

_edit_
I'm still acclimating myself to npm. I was able to resolve this by manually editing package.json to use babel-runtime@^6.0.0. I had also mistakenly included babel-runtime under "dependencies". Clearing this out resolved my warning.

Was this page helpful?
0 / 5 - 0 ratings