func (g *Game) InitDom(ctx context.Context, wg *sync.WaitGroup) {
	jsFuncs := map[string]js.Func{
		"create":            g.dom.NewJsFunc(g.startCreate),
		"createWithConfig":  g.dom.NewJsEventFunc(g.createWithConfig),
		"join":              g.dom.NewJsEventFunc(g.join),
		"leave":             g.dom.NewJsFunc(g.sendLeave),
		"delete":            g.dom.NewJsFunc(g.delete),
		"start":             g.dom.NewJsFunc(g.Start),
		"finish":            g.dom.NewJsFunc(g.finish),
		"snagTile":          g.dom.NewJsFunc(g.snagTile),
		"swapTile":          g.dom.NewJsFunc(g.startTileSwap),
		"sendChat":          g.dom.NewJsEventFunc(g.sendChat),
		"resizeTiles":       g.dom.NewJsFunc(g.resizeTiles),
		"refreshTileLength": g.dom.NewJsFunc(g.refreshTileLength),
		"viewFinalBoard":    g.dom.NewJsFunc(g.viewFinalBoard),
	}
	g.dom.RegisterFuncs(ctx, wg, "game", jsFuncs)
}
// InitDom registers game dom functions.
InitDom registers game dom functions.
// InitDom registers game dom functions .
func (g *Game) InitDom(ctx context.Context, wg *sync.WaitGroup) {
	jsFuncs := map[string]js.Func{
		"create":            g.dom.NewJsFunc(g.startCreate),
		"createWithConfig":  g.dom.NewJsEventFunc(g.createWithConfig),
		"join":              g.dom.NewJsEventFunc(g.join),
		"leave":             g.dom.NewJsFunc(g.sendLeave),
		"delete":            g.dom.NewJsFunc(g.delete),
		"start":             g.dom.NewJsFunc(g.Start),
		"finish":            g.dom.NewJsFunc(g.finish),
		"snagTile":          g.dom.NewJsFunc(g.snagTile),
		"swapTile":          g.dom.NewJsFunc(g.startTileSwap),
		"sendChat":          g.dom.NewJsEventFunc(g.sendChat),
		"resizeTiles":       g.dom.NewJsFunc(g.resizeTiles),
		"refreshTileLength": g.dom.NewJsFunc(g.refreshTileLength),
		"viewFinalBoard":    g.dom.NewJsFunc(g.viewFinalBoard),
	}
	g.dom.RegisterFuncs(ctx, wg, "game", jsFuncs)
}
func ( g * Game ) InitDom ( ctx context . Context , wg * sync . WaitGroup ) { jsFuncs := map [ string ] js . Func { " " : g . dom . NewJsFunc ( g . startCreate ) , " " : g . dom . NewJsEventFunc ( g . createWithConfig ) , " " : g . dom . NewJsEventFunc ( g . join ) , " " : g . dom . NewJsFunc ( g . sendLeave ) , " " : g . dom . NewJsFunc ( g . delete ) , " " : g . dom . NewJsFunc ( g . Start ) , " " : g . dom . NewJsFunc ( g . finish ) , " " : g . dom . NewJsFunc ( g . snagTile ) , " " : g . dom . NewJsFunc ( g . startTileSwap ) , " " : g . dom . NewJsEventFunc ( g . sendChat ) , " " : g . dom . NewJsFunc ( g . resizeTiles ) , " " : g . dom . NewJsFunc ( g . refreshTileLength ) , " " : g . dom . NewJsFunc ( g . viewFinalBoard ) , } g . dom . RegisterFuncs ( ctx , wg , " " , jsFuncs ) }
InitDom registers game dom functions.
InitDom registers game dom functions .