dnd-kit icon indicating copy to clipboard operation
dnd-kit copied to clipboard

[experimental] Add official SolidJS adapter maintained by community

Open kachurun opened this issue 9 months ago • 2 comments

Hi mates 👋

I’ve built dnd-kit-solid – a SolidJS adapter for @dnd-kit/dom, fully aligned with the structure and API of the React version (@dnd-kit/react). It supports all the core features and provides Solid-friendly hooks and components. I'm also planning to add extra components like Draggable, Droppable, and Sortable.

I’d love to contribute it directly to this repo under an @dnd-kit/solid package (similar to how @dnd-kit/react is structured), if that’s possible. I’ll take full responsibility for maintaining it and keeping it up to date with changes in the core.

Let me know what you think! I'd be happy to open a PR if you're open to the idea 🙏

kachurun avatar Apr 13 '25 07:04 kachurun

Hey @kachurun, I took a quick look at the code and it looks great 💯 I'm no expert with SignalJS but would happily accept your contributions if you're up for it 🙏

You could also add documentation for it in /apps/docs. I think storybook would be a bit more complex to set up for multi-framework but something we could look into later down the road.

clauderic avatar Apr 13 '25 14:04 clauderic

Thanks a lot, glad you liked it!

I’ll need a bit of time to test it properly in the production of my main project and make sure everything works as expected. I’m especially keeping an eye on some edge cases with Sortable - I suspect there might be a few hiccups that need smoothing out. Also thinking of tweaking or aligning some APIs if needed, and I’ve got a few ideas I wanna try out on the API design side (like event handlers for useDraggable).

Docs - absolutely, that’s on me. I’ll add a section to /apps/docs once the package is stable.

As for Storybook - I’ve got it running with SolidJS in my main project, so I’m familiar with the setup. Making it work nicely across multiple JSX frameworks might be a bit tricky, but I’m sure we’ll figure it out eventually.

Will keep you posted once it’s ready to go!

kachurun avatar Apr 13 '25 18:04 kachurun