webpack-external-import icon indicating copy to clipboard operation
webpack-external-import copied to clipboard

Two identical ExteranlComponents will only render one

Open mathan78 opened this issue 5 years ago • 2 comments

As the subject says, if you have two identical ExternalComponent on the same page, then, strangely, it will only render one of them. It seems like the interleave promise in v2Effect never resolves on the second component.

To reproduce, copy/duplicate the website-2/TitleComponent into Website1s App.jsx.

mathan78 avatar Feb 11 '20 20:02 mathan78

Did some more testing. If I load the component without ExternalComponent, then I can render them twice. (I.e. only calling interleave once, not twice as ExternalComponent would.) Can we keep track of modules already loaded and not fetch them again in ExternalComponent?

mathan78 avatar Feb 11 '20 21:02 mathan78

Known flaw. This will be fixed with v3 - currently 50% done and will be merged into webpack core

ScriptedAlchemy avatar Feb 15 '20 22:02 ScriptedAlchemy