Comments (13)
Released with v7.
from embla-carousel.
@rojadesign would you mind creating a CodeSandbox with your setup? That’s a requirement from my side if you want me to debug and hopefully pinpoint why this is happening.
from embla-carousel.
@davidjerleke thank you for your time. Here is the Vue3 + TypeScript template used - not really working but the same error I have locally also appears there:
Property 'clickAllowed' does not exist on type 'EmblaCarouselType | HTMLElement'.
Property 'clickAllowed' does not exist on type 'HTMLElement'.ts(2339)
from embla-carousel.
@rojadesign yes, this is clearly a TypeScript related bug in the embla-carousel-vue
package because the typings are wrong. The type for emblaApi
should be EmblaCarouselType | null
. I'll have to look into this when possible. Feel free to propose a solution if you want. The Vue wrapper code is here.
Thank you for reporting this. I created the following bug report where we can track the bug:
Best,
David
from embla-carousel.
Is it working with Vue 2 + @nuxtjs/composition-api ?
from embla-carousel.
@sinneren thank you for your question. It only works with Vue 3.
from embla-carousel.
@davidjerleke I'm not sure if I do something wrong and maybe it's a dumb question, but how can I access the clickAllowed
method?
I only get scrollTo
suggested, as no other property seems to exist:
Edit: seems to be a TypeScript error but I don't get why the scrollTo
is shown as available.
from embla-carousel.
@davidjerleke thank you for your response. Here is a link to the sandbox. I'm not sure if the vue setup
syntax is a problem or maybe the only problem.
from embla-carousel.
@rojadesign I think the setup is not working as expected because importing onMounted
shouldn't cause any errors. Would you mind trying the following Vue3 + TypeScript template instead?
from embla-carousel.
Hello,
Can this work with the api option ? I can't.
from embla-carousel.
@spoitler I don’t understand the question. Would you mind clarifying what you mean?
from embla-carousel.
is it necessary to use the setup() function to initialize it ?
from embla-carousel.
@spoitler yes I think so.
from embla-carousel.
Related Issues (20)
- [Bug]: When the direction is set to 'rtl' and the loop is set to true, it doesn't loop infinitely HOT 1
- [Bug]: canScrollNext method returns false even when there are items to scroll HOT 1
- [Bug]: AutoScroll position jumps when clicked and dragged HOT 7
- [Bug]: Input click block after dragging HOT 2
- [Feat]: Add TypeScript moduleResolution: bundler support HOT 11
- [Bug]: Autplay stops working after drag HOT 2
- [Bug]: Cannot find module 'embla-carousel/components/Options' or its corresponding type declarations. TypeScript, React with Vite HOT 2
- [Bug]: Flickering when adding icon or image in slides (8.0) HOT 3
- [Bug]: Direction rtl reverses y axis direction HOT 5
- [Bug]: Slide hanging if overdragged/scrolled HOT 5
- [Bug]: Angular autoplay error HOT 1
- [Bug]: Autoplay fast scroll when opened in a new tab HOT 7
- [Bug]: no specific name for plugin import, have to use "index" instead HOT 4
- [Bug]: Embla Carousel's animation becomes less smooth when the battery saving mode is enabled. HOT 1
- [Bug]: Render when slides are wider than view size HOT 5
- [Bug]: When using the wheel gesture to swipe the carousel, for the first slide and the last slide, there are excessive blank space. HOT 2
- [Bug]: Thumbnails example won't work in RTL HOT 2
- [Bug]: Height is getting set to 0 HOT 4
- [Bug]: Scroll broken after direction update HOT 15
- [Bug]: Jest testing bug return TypeError: undefined is not a function HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from embla-carousel.