-
Notifications
You must be signed in to change notification settings - Fork 55
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
How to run Resize on load? #37
Comments
Maybe try this:
|
Thanks a lot for the reply. Unfortunately nothing changes on my end.
|
Any solution for this problem? |
I use setTimeout with 1 second but it not a good idea!
|
Use this.$refs.flickity.rerender(); instead of this.$refs.flickity.resize(); works for me ;) |
@EnzoBatista Hm, interesting! That doesn't work for me, I can't seem to find this rerender() method in the flickity api or on the flickity object. Can you tell us a bit more? |
@emdahlstrom Dude, i've used rerender() method in nuxt like this this.$refs.flickity.rerender();, but i think it's available in react js too and in some way you can do this in vue js |
Not work for me now :/ we're using SSR btw maybe that's why didn't work |
Hoping someone can help with this issue.
This is not working. I'm getting:
[Vue warn]: Error in beforeMount hook: "TypeError: Cannot read property 'resize' of undefined"
if I use mounted() I don't get an error but the slides aren't resized.
If I put it in a button, resize works on click:
<button @click="resize()">Resize That
The text was updated successfully, but these errors were encountered: