Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Possibly add external dependencies on the last chunk only #3

Open
swashata opened this issue Nov 14, 2018 · 0 comments
Open

Possibly add external dependencies on the last chunk only #3

swashata opened this issue Nov 14, 2018 · 0 comments

Comments

@swashata
Copy link
Owner

Multiple entry-points from the same files entry have common dependency.

Now one of the entry point may depend on say wp-blocks, but not the other. In this
case with current approach, we add wp-blocks to every entry chunks, including runtime, vendor etc.

So depending on which entry-point we have called first, additional external WordPress dependencies might come to the page where it shouldn't.

To solve this, we can

  1. Split files entry through multi-compiler mode where we know that none of them share anything common.
  2. Or just add the external WP dependencies to the last chunk of an entry-point.

I am not sure if 2 should be a good approach here. Because in theory, the vendor could have external dependency too.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant