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

TypeError: Cannot read properties of undefined (reading 'header') #254

Open
IrinaLuminesk opened this issue Jan 29, 2024 · 9 comments
Open

Comments

@IrinaLuminesk
Copy link

I currently getting this error on vue 3. This is my code
image
image

And this is the error show on my browser
image

@vladfr
Copy link

vladfr commented Feb 21, 2024

Getting this too. And if you add the #header slot, you bump into other errors. It's because this.$scopedSlots is undefined, but I have no idea why. This happens only in very recent versions of Vue3. It didn't use to be like this before.

I'm on [email protected] and using Nuxt.

Interestingly enough, on Vue 3.4.15 with a default Vuetify setup, this library works with the same code.

@bblumenfelder
Copy link

Getting the same error, but I'm not willing to install Vuetify :)
Did you find another solution?

@zhelingwang
Copy link

zhelingwang commented Apr 3, 2024

package version:
"vue": "^3.4.21", "vuedraggable": "^4.0.1"

code:

<draggable :list="myArray" item-key="name" ghost-class="ghost" @start="drag = true" @end="drag = false">
        <template #item="{ element }">
            <div class="list-group-item">{{ element.name }}</div>
        </template>
</draggable>

"vuedraggable": "^4.0.1" 这个版本后我这边正常, 没有出现这个错误了

@prashantnirgun
Copy link

this still not work with "vuedraggable": "^4.0.1",

@Lippiece
Copy link

Updating Vue to latest will probably fix this, as it fixed mine.

@ReljaMihajlovic
Copy link

ReljaMihajlovic commented May 20, 2024

I fixed it by shutting down dev server and then running npm run dev again. "vue": "^3.4.27", "vuedraggable": "^4.1.0"

@emirrozerr
Copy link

I fixed it by shutting down dev server and then running npm run dev again. "vue": "^3.4.27", "vuedraggable": "^4.1.0"

Same here!

@ecolovecat
Copy link

Just shut down the server and then rerun. If still not work, install to the "vuedraggable": "^4.1.0", then rerun the server again

@chenyajin
Copy link

package version:
"vue": "^3.4.21", "vuedraggable": "^4.1.0"

solution:
delete node_modules and clean npm

it works for me!

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

10 participants