Replies: 5 comments 1 reply
-
I'd feel it's the env you use does not support postinstall hook, maybe try |
Beta Was this translation helpful? Give feedback.
-
StackBlitz: It indeed looks like the CodeSandbox: I'm confused as to how it would work in CodeSandbox for Vue 3, but not Vue 2. |
Beta Was this translation helpful? Give feedback.
-
|
Beta Was this translation helpful? Give feedback.
-
I'm trying to make a demo for my library using |
Beta Was this translation helpful? Give feedback.
-
Managed to get it working on a nuxt container which have access to terminal |
Beta Was this translation helpful? Give feedback.
-
For some reason, Vuelidate's
useVuelidate()
function crashes onvue-demi
'sgetCurrentInstance()
, but only in Codesandbox (with Vue 2 only) and StackBlitz (any version of Vue).I initially opened a Vuelidate issue, but they punted to
vue-demi
.Following the guide for using Vuelidate with Composition API, I'm seeing an error when
useVuelidate()
is called:This seems to occur only in Codesandbox or StackBlitz. Running the same code in a Vue CLI scaffolded project works fine.
Stack trace
Reproduction URL
https://codesandbox.io/s/usevuelidate-bug-getcurrentinstance-is-not-a-function-6rx9w
or
https://stackblitz.com/edit/vuelidate-bug-demo
To Reproduce
Steps to reproduce the behavior:
Create new Codesandbox for Vue 2 (or fork Vuelidate's official Vue 3 + Composition API Starter and switch Vue version to 2.x).
Add dependency for
@vue/composition-api
, and install it frommain.js
:Open
src/App.vue
, and copy Vuelidate guide's example code for the Composition API usage:See error in browser console
Expected behavior
The same output from Vuelidate's official Vue 3 + Composition API Starter.
Screenshots
Additional context
vue
2.6.14@vue/composition-api
1.0.0-rc.11@vuelidate/core
2.0.0-alpha.14 (also newer versions, including 2.0.0-alpha.19)@vuelidate/validators
2.0.0-alpha.12 (also newer versions, including 2.0.0-alpha.17)Beta Was this translation helpful? Give feedback.
All reactions