-
Notifications
You must be signed in to change notification settings - Fork 30
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
Typescript and framework integration #73
Comments
Thank you for supporting and taking Swiffy Slider for a spin. I have little experience with TS so I cannot say much here. Swiffy Slider comes in classic JS that can be included in script tags or you can import it as an ESM. I am a huge fan of simple things and following standards. It is fine to add TS support - but if it requires complexity and going away from standards, I might not be in favor. Feel free to create a pull so I can see the implications. Thanks, Nicolai |
@nicped You don't need to change your code. You (or someone else) could simply create a new package Anyway. I like simple things too. Instead Typescript i prefer for small scripts just jsdoc, that is sadly missing in your code and could be helpful. VSCode supports it and use it for linting too. |
I can go with adding the JSDoc - as they are minified away and does not come with any requirements. Even though the comments pollute the src code :-) I am either too smart or not smart enough to add TS types.... Your call!. But feel free to create a package,. |
👍 on adding JS doc. I'll be available only in a couple of weeks before getting into it |
Is your feature request related to a problem? Please describe.
For those working with typescript, integrating Swiffy-slider requires some work. In my case, the builder.io Qwik framework but it applies to any others like Remix.
Describe the solution you'd like
Make Swiffy-slider Typescript friendly and/or submit a type in
@types/*
repoDescribe alternatives you've considered
There isn't much alternative.
Additional context
Using the reference of
window
shall eventually be reconsidered in order to make the integration within other frameworks easier.I've already worked on it and got a simple Typescript support.
If interested, I would create a new branch using this issue's ID.
The text was updated successfully, but these errors were encountered: