MCPcopy Create free account
hub / github.com/wavetermdev/waveterm / withGlobalRenderCtx

Function withGlobalRenderCtx

tsunami/engine/globalctx.go:58–62  ·  view source on GitHub ↗
(vc *RenderContextImpl, fn func() T)

Source from the content-addressed store, hash-verified

56}
57
58func withGlobalRenderCtx[T any](vc *RenderContextImpl, fn func() T) T {
59 setGlobalRenderContext(vc)
60 defer clearGlobalRenderContext()
61 return fn()
62}
63
64func GetGlobalRenderContext() *RenderContextImpl {
65 globalCtxMutex.Lock()

Callers 1

renderComponentMethod · 0.85

Calls 2

setGlobalRenderContextFunction · 0.85
clearGlobalRenderContextFunction · 0.85

Tested by

no test coverage detected