vue-web-component icon indicating copy to clipboard operation
vue-web-component copied to clipboard

is example working ?

Open jgribonvald opened this issue 7 years ago • 6 comments

Hi,

I'm trying to follow your example but it seems there is a problem with the browser, I'm getting this error when runing the wc : Uncaught TypeError: Cannot read property 'props' of undefined at initialize (vue-wc-wrapper.js:113) at wrap (vue-wc-wrapper.js:261) at Module.WnQP (entry-wc.js:11) at webpack_require (bootstrap:19) at bootstrap:83 at bootstrap:83 But the wc seems to work !

Do you have the same error ?

jgribonvald avatar Jun 26 '18 15:06 jgribonvald

Works fine for me. Here are the commands I used:

npm run build -- --wc

Then server the dist directory and it works

anthonygore avatar Jul 08 '18 04:07 anthonygore

not sure this come from that so, maybe its due to vue-cli-service version, I'm running the 3.0.0-rc3

"build": "vue-cli-service build --name wc-name --target wc" + npm run build

jgribonvald avatar Jul 09 '18 13:07 jgribonvald

Can you tell me the commands you are running and what is happening?

anthonygore avatar Jul 09 '18 14:07 anthonygore

I'm running npm run build and having in package.json the build command vue-cli-service build --name wc-name --target wc I don't get error when running it, the error is a console log at launch and is only when using the dist package into my html, but the component is running !

jgribonvald avatar Jul 09 '18 15:07 jgribonvald

I'm not sure of the problem, sorry. It works for me following the same steps...

anthonygore avatar Jul 18 '18 02:07 anthonygore

this error doesn't appear anymore after updating dev dependencies.. Thanks

jgribonvald avatar Jul 18 '18 07:07 jgribonvald