-
Notifications
You must be signed in to change notification settings - Fork 87
Using { useBuiltIns: usage } causes circular dependencies #254
Comments
I've created a minimal implementation. If I run
The build completes, but if I run it, I get the same error:
The problem does go away if I set |
Also, |
The issue is that Babel configuration in a The job of If you absolutely need to compile things in Compiling |
Thanks! That makes sense. I did try excluding |
Confirming that Thanks for creating babel/babel#8754 as well. Very curious to see what the outcome of that will be. |
「Circular dependency」警告の発生と実行不可能なスクリプトが生成される問題でかなり手こずったものの、解決に成功した。 なぜこれで上手くいくのかよく解っていないが、excludeオプションは必須。 参考: * rollup/rollup-plugin-babel#254 * rollup/rollup-plugin-babel#313 (comment) * https://github.com/rollup/rollup-plugin-babel/blob/a5489208c33dd99f71a3f30b228fd02d18008b5f/README.md#external-dependencies
If I change my
preset-env
config from the default{ useBuiltIns: false }
to'usage'
, I get tons of circular dependency warnings from Rollup, e.g.,And then my bundle crashes on this statement in core-js:
where
_export
is undefined. So that looks a lot like the circular dependency hadn't been populated yet upon the call to it. If I comment out that statement, it just crashes on the next occurrence of_export
.The question is, of course, what causes the circular dependency to be introduced. One possibility is that the core-js code itself is getting run through Babel somehow.
I'm using the latest versions of
node-resolve
,commonjs
, andbabel
(+preset-env
), in that order.In #250, you recommend trying the beta version, but unfortunately, I get the same behavior with v4.1.0-0.
I realize this is not necessarily an issue with this plugin, but unfortunately, it's really hard for me to debug it outside of Rollup. Any input you might have is appreciated. Thanks!
The text was updated successfully, but these errors were encountered: