func (dom *DOM) RegisterFuncs(ctx context.Context, wg *sync.WaitGroup, parentName string, jsFuncs map[string]js.Func) {
	parent := dom.global.Get(parentName)
	if parent.IsUndefined() {
		parent = js.ValueOf(make(map[string]interface{}))
		dom.global.Set(parentName, parent)
	}
	for fnName, fn := range jsFuncs {
		parent.Set(fnName, fn)
	}
	wg.Add(1)
	go dom.ReleaseJsFuncsOnDone(ctx, wg, jsFuncs)
}
// RegisterFuncs sets the function as fields on the parent.
// The parent object is created if it does not exist.
RegisterFuncs sets the function as fields on the parent.
The parent object is created if it does not exist.
// RegisterFuncs sets the function as fields on the parent . // The parent object is created if it does not exist .
func (dom *DOM) RegisterFuncs(ctx context.Context, wg *sync.WaitGroup, parentName string, jsFuncs map[string]js.Func) {
	parent := dom.global.Get(parentName)
	if parent.IsUndefined() {
		parent = js.ValueOf(make(map[string]interface{}))
		dom.global.Set(parentName, parent)
	}
	for fnName, fn := range jsFuncs {
		parent.Set(fnName, fn)
	}
	wg.Add(1)
	go dom.ReleaseJsFuncsOnDone(ctx, wg, jsFuncs)
}
func ( dom * DOM ) RegisterFuncs ( ctx context . Context , wg * sync . WaitGroup , parentName string , jsFuncs map [ string ] js . Func ) { parent := dom . global . Get ( parentName ) if parent . IsUndefined ( ) { parent = js . ValueOf ( make ( map [ string ] interface { } ) ) dom . global . Set ( parentName , parent ) } for fnName , fn := range jsFuncs { parent . Set ( fnName , fn ) } wg . Add ( 1 ) go dom . ReleaseJsFuncsOnDone ( ctx , wg , jsFuncs ) }
RegisterFuncs sets the function as fields on the parent.
RegisterFuncs sets the function as fields on the parent .