Function · Hooks and State
useEffect
Runs an effect after the native tree commits and cleans it up before rerun or unmount.
@sharpts/gui · SharpTS 572a2e31be0eSignature
TypeScript
useEffect(effect: () => any, deps?: readonly unknown[]): voidParameters
| Name | Type | Description |
|---|---|---|
effect | () => any | Effect callback, optionally returning a cleanup callback. |
deps optional | readonly unknown[] | Optional dependency values controlling reruns. |
Source
src/SharpTS.Gui.Sdk/GuiPackage/runtime.ts:258 at SharpTS revision 572a2e31be0e2a09be0138bc44501b34d6245b51.