SolidJSS
SolidJS2w ago
3 replies
Lȩge

Void signal

A signal that doesn't hold a value, but can be used for tracking.

function createVoidSignal(): {track: () => void, touch: () => void}


Track is called to track the signal, touch is called to update tracked dependencies.

It would be possible to make this using a signal that just alternates between true and false, but is there a cleaner way to make this that genuinely doesn't store any state?
Was this page helpful?