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
[Feat]: Add TypeScript moduleResolution: bundler support #778
Comments
@crashton28 thanks for your bug report. Please create a minimal reproduction environment and share steps to reproduce the problem as it’s mandatory if you want me to look into this. Best, |
I've added a codesandbox demo to the original issue above |
@crashton28 thanks. Unfortunately I can't access files under As you mention, setting But I don't know why yet. Feel free to help me out and read about the new It feels like devs spend 90% of their time with bundlers and problems related to them so I'm happy that we finally we have yet another option that can cause bundling problems. Yaay 😉! Best, |
@davidjerleke The node_modules for a Direct link to the autoplay declaractions for example: https://codesandbox.io/p/devbox/embla-carousel-autoplay-react-forked-7tkpmg?file=%2Fnode_modules%2F.pnpm%2Fembla-carousel-autoplay%408.0.0_embla-carousel%408.0.0%2Fnode_modules%2Fembla-carousel-autoplay%2Fesm%2Fcomponents%2FAutoplay.d.ts |
@crashton28 thanks. I will look into it when possible. Until then: Feel free to help out. Best, |
No, I mean anyone can access the node_modules of a codesandox on that website. The screenshot shows you where it is and the link brings you there directly. 😄 |
@paulmolluzzo yes thanks. Didn’t know that so debugging will be less cumbersome know that you made me aware of that. No need to create a local project 🙂. |
Changing label to feature request because |
Anyone who wants to contribute can look into this issue, because it doesn't require any prior knowledge of how Embla works. I'm busy building the fade plugin so it would really help. Best, |
Hi David, I made a PoC on embla-carousel-react and its dependencies on this fork. I've integrated this version into one of my React applications for testing. My commits are a bit messy cause I struggled with rollup and versionning. I disabled the docs to focus only on the modules I needed and I didn't adapt the tests. I think it'll be a good oppotunity to use vitest (that's why I switched to nodenext on my repos). Basically the main change is specifying the files extension so that Typescript knows if it's a cjs file or not, here for example, . I might do a complete PR if I have the time. Best, |
Which variants of Embla Carousel are you using?
Steps to reproduce
In attempting to use the
isPlaying
method as well as theautoplay:stop
andautoplay:play
event listeners the types are not found. This project is currently within a monorepo and usingpnpm
.We are able to resolve the issue by updating our
tsconfig
with the following, however we are not able to make this change as we needmoduleResolution
to be set tobundler
for our builds.Screenshots of the errors within VSCode
Expected Behavior
Types would have been found
Additional Context
I have also tried...
What browsers are you seeing the problem on?
No response
Version
v8.0.0
CodeSandbox
CodeSandbox: Monorepo with TS Error
Before submitting
The text was updated successfully, but these errors were encountered: