serveui

package
v0.9.21 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 3, 2026 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AssetVersion added in v0.0.118

func AssetVersion() string

AssetVersion returns a stable hash of the chat UI assets. The standalone Hub entry has an independent version so changes to either application do not rotate the other application's cache identity.

func HubAssetVersion added in v0.9.19

func HubAssetVersion() string

HubAssetVersion returns a stable hash over exactly the standalone Hub entry module and stylesheet.

func IndexHTML

func IndexHTML() []byte

IndexHTML returns the embedded UI page.

func RenderIndexHTML added in v0.0.118

func RenderIndexHTML(basePath, headSnippet string, _ RenderOptions) []byte

RenderIndexHTML returns the Preact entry page with versioned cacheable assets, a canonical network-first module entry, caller-supplied head markup, and the exact relative base-path contract.

func RenderManifest added in v0.0.118

func RenderManifest() []byte

RenderManifest returns the manifest with versioned icon URLs. The returned slice is cached and must be treated as read-only.

func RenderServiceWorker added in v0.0.118

func RenderServiceWorker(_ RenderOptions) []byte

RenderServiceWorker returns the service worker with a versioned cache key and generated shell asset URLs. The canonical app entry and stable-named Vite chunks deliberately remain unversioned and network-first so every import uses one module identity and deployments cannot execute an old dependency graph.

func StaticAsset added in v0.0.106

func StaticAsset(name string) ([]byte, error)

StaticAsset returns a copy of an embedded serve-ui asset.

Types

type RenderOptions added in v0.0.216

type RenderOptions struct {
	WebRTC bool
}

RenderOptions controls optional UI features included in rendered UI assets.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL