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

Error when using 2 vue based webcomponent libraries on the same page #1150

Closed
batje opened this issue Apr 19, 2018 · 0 comments
Closed

Error when using 2 vue based webcomponent libraries on the same page #1150

batje opened this issue Apr 19, 2018 · 0 comments

Comments

@batje
Copy link

batje commented Apr 19, 2018

Version

3.0.0-beta.6

Reproduction link

https://github.com/batje/twocomponents

Steps to reproduce

  • run npm install in the /component1 subfolder
  • open the 'working.html' and 'failing.html' in your browser

The error will happing in the file failing.html (see your console)

What is expected?

If I have 2 webcomponent libraries with separate compiles, they should both work.

What is actually happening?

the second webcomponent generates an error and is invisible, because the first webpack_require instance is queried.


By adding the output.library option to the webpack config, each webcomponent library gets its own namespace.

This is implemented in component3 in the vue,config.js file , but should be standard, imho.

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

2 participants