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

globally accessible vendor chunk #1532

Closed
alexsoin opened this issue Aug 18, 2021 · 1 comment
Closed

globally accessible vendor chunk #1532

alexsoin opened this issue Aug 18, 2021 · 1 comment

Comments

@alexsoin
Copy link

Please tell me how to create a vendor.js file with global access dependencies (collected from imports located in the node_modules) through the esbuild during assembly, by analogy with the work of webpack chunks:

// webpack.config.js
...
optimization: {
  splitChunks: {
    chunks: 'all',
    maxInitialRequests: Infinity,
    minSize: 0,
    cacheGroups: {
    vendor: {
      test: /[\\/]node_modules[\\/]/,
      name: "vendor"
    },
    },
  },
}
...

How can I also collect two files of main.js and vendor.js in esbuild? I read the documentation and looked at the plugins, I could not find a solution for this problem.

@evanw
Copy link
Owner

evanw commented Oct 17, 2021

This is not currently possible, and is an active feature request. Closing this duplicate issue in favor of #207.

@evanw evanw closed this as completed Oct 17, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants