preactjs / signals

Manage state with style in every framework
https://preactjs.com/blog/introducing-signals/
MIT License
3.71k stars 91 forks source link

Devtools for debug #384

Closed timsofteng closed 8 months ago

timsofteng commented 1 year ago

Hello. It would be cool to have some tool for debugging signals.

rschristian commented 1 year ago

The Preact devtools browser extension does support signals I believe.

timsofteng commented 1 year ago

The Preact devtools browser extension does support signals I believe.

Does it work with react?

rschristian commented 1 year ago

It will not, no.

Someone could fork React's devtools, add in support for signals, and rerelease, but that'd be a lot of work and maintenance so it's probably unlikely to happen. Maybe someone in the community is interested in that though, not sure.

rschristian commented 8 months ago

Closing this out, this would need to be handled upstream. I don't think we'll be making dedicated devtools for signals.

y0n3r commented 6 months ago

@timsofteng Have you found anything for Signals dev tools support when used with React? I've been combing the internet and haven't really found anything. But, I noticed that if you create your initial app state with Signals and pass it down to your app using Context, you can highlight the provider in React Dev Tools and then click on the Log this component data to the console icon and get all of the corresponding values inside of the console. It's obviously not ideal and not as dynamic as just inspecting via dev tools, but it's way better than nothing. I hope this helps and I'll be continuing my search elsewhere...