-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
webpack 4 production build Converting circular structure to JSON #870
Comments
Could you please add a screenshot with the content of the value which is stringified? |
Console response not show stringify content. |
You can add a
|
I see the above from this kind of stack trace:
|
My code works fine with webpack 3 but 4
If change to
It work fine with my code and i don't know why Here is a copy of this code
click to expand log
|
I've just had the same error. I rebuilt a new project with the same The error message is I reviewed my code again. I found a template file which imported in the routing file. In that template file, I called a libarary that called the routing file. So there's a cycle. Isn't it? /(ㄒoㄒ)/~~ In webpack3, there is no such error. webpack4 changes the chunk method, review your code and see if there is a cycle. |
@willove |
+1, @jantimon You can checkout https://github.com/JounQin/ng-rubick/blob/master/src/views/app.routing.module.ts#L8-L11 and uncomment there lines, then simply run |
work around: add chunksSortMode option and set it to "none" |
@kenotron Cool, that works to me. |
@kenotron You're a life saver! Adding chunksSortMode: "none" worked for me too. For anyone else using this workaround though: you need to add it for all templates (even ones that don't include chunks). |
@kenotron worked for me also! |
@kenotron You are the best. Works perfectly. Thanks |
Reproduction in case anyone needs it. Error is thrown when building angular app in AoT mode. |
@kenotron won't say It's a work around. cause it will breaks the script run order which breaks the app. |
@lili21 with webpack 4 the order of scripts should not matter anymore |
wow, really ? didn't know that before. |
@kenotron worked for me, thanks! |
#953 tries to solve this issue - please let me know if there are any problems with the proposed solution. |
Could you please try if this works for you with 4.x alpha?
|
@jantimon It fixed the problem for my reproduction. Thanks a lot! |
still having the issue here after a |
@darkylmnx it's hard to tell without seeing your configuration - can you please create a new bug ticket for that? |
Hi,
on newest webpack 4.0.1 and html-webpack-plugin 3.0.3 i get this error
its production build for angular 5.2.7
The text was updated successfully, but these errors were encountered: