MCPcopy Index your code
hub / github.com/wavetermdev/waveterm / UseRef

Function UseRef

tsunami/engine/hooks.go:103–110  ·  view source on GitHub ↗
(vc *RenderContextImpl, hookInitialVal any)

Source from the content-addressed store, hash-verified

101}
102
103func UseRef(vc *RenderContextImpl, hookInitialVal any) any {
104 hookVal := vc.getOrderedHook()
105 if !hookVal.Init {
106 hookVal.Init = true
107 hookVal.Val = hookInitialVal
108 }
109 return hookVal.Val
110}
111
112func depsEqual(deps1 []any, deps2 []any) bool {
113 if len(deps1) != len(deps2) {

Callers 1

UseRefFunction · 0.92

Calls 1

getOrderedHookMethod · 0.80

Tested by

no test coverage detected