Versions in this module Expand all Collapse all v0 v0.1.1 Jul 20, 2026 v0.1.0 Jul 20, 2026 Changes in this version + func BundleComponent(componentPath string, opts ...BundleOptions) (string, error) + func BundleComponentModule(componentPath string, opts ...BundleOptions) (string, error) + func BundleComponentModules(componentPaths []string, opts ...BundleOptions) (map[string]string, error) + func BundlePreload(modulePath string, name string) (string, error) + func BundleSharedRuntime(nodePaths []string, modules map[string]string, opts ...BundleOptions) (string, error) + func BundleSource(source string, opts ...BundleOptions) (string, error) + func BundleStandaloneModule(modulePath string) (string, error) + func DiscoverExternalPackages(componentPaths []string, nodePaths []string, opts ...BundleOptions) ([]string, error) + func DiscoverTagName(source string) (string, error) + func ExtractDynamicImportTargets(modules map[string]string) []string + func ExtractUnrewrittenImports(modules map[string]string) []string + func FindAllNodeModules(fromPath string) []string + func ResolveModulePath(specifier string, fromDir string) (string, error) + func RewriteModuleImports(modules map[string]string, externals []string) map[string]string + func SaveBundle(bundle string, path string) error + type BatchRequest struct + Attrs map[string]string + ID int + TagName string + type BatchResult struct + CSS string + Error string + HTML string + ID int + TagName string + type BundleOptions struct + Conditions []string + ExternalPackages []string + Format api.Format + MainFields []string + Minify bool + Platform api.Platform + Target api.Target + type Engine struct + func NewEngine() (*Engine, error) + func (e *Engine) Close() + func (e *Engine) CompileModule(name string, source string) ([]byte, error) + func (e *Engine) EvalModule(name string, source string) error + func (e *Engine) EvalModuleBytecode(name string, bc []byte) error + func (e *Engine) IsRegistered(tagName string) bool + func (e *Engine) LoadBundle(bundle string) error + func (e *Engine) LoadBundleForTag(tagName string, registry *Registry) (bool, error) + func (e *Engine) LoadModule(name string, source string) error + func (e *Engine) LoadModuleBytecode(name string, bc []byte) error + func (e *Engine) RenderBatch(requests []BatchRequest) ([]BatchResult, error) + func (e *Engine) RenderElement(tagName string, attrs map[string]string) (*RenderResult, error) + func (e *Engine) Reset() error + func (e *Engine) SetPreloadModules(modules []string) + func (e *Engine) SetRuntimeExternals(externals []string) + type EnginePool struct + func NewEnginePool(size int) (*EnginePool, error) + func (p *EnginePool) Available() int + func (p *EnginePool) Close() + func (p *EnginePool) Get() *Engine + func (p *EnginePool) PreloadAll(registry *Registry, preloadModules []string, preloadBundles ...string) error + func (p *EnginePool) Put(e *Engine) + func (p *EnginePool) Size() int + type ImportMap struct + BaseDir string + Imports map[string]string + Scopes map[string]map[string]string + func LoadImportMapFile(path string) (*ImportMap, error) + func ParseImportMap(jsonStr string, baseDir string) (*ImportMap, error) + func (im *ImportMap) Resolve(specifier string) string + func (im *ImportMap) ResolveAll(specifiers []string) []string + type Registry struct + func NewRegistry() *Registry + func (r *Registry) BaseDir() string + func (r *Registry) DynamicImportTargets() []string + func (r *Registry) DynamicModules() map[string]string + func (r *Registry) Has(tagName string) bool + func (r *Registry) HasBytecode() bool + func (r *Registry) HasPath(path string) bool + func (r *Registry) IsUnregistered(tagName string) bool + func (r *Registry) LoadCompiled(path string) error + func (r *Registry) LoadDir(dir string) error + func (r *Registry) LoadFile(path string) error + func (r *Registry) LoadSourceDir(dir string) error + func (r *Registry) Lookup(tagName string) string + func (r *Registry) LookupBytecode(name string) []byte + func (r *Registry) LookupModule(tagName string) string + func (r *Registry) MarkPath(path string) + func (r *Registry) MarkUnregistered(tagName string) + func (r *Registry) ProcessedPaths() []string + func (r *Registry) Register(tagName string, source string) + func (r *Registry) RegisterModule(tagName string, source string) + func (r *Registry) RuntimeExternals() []string + func (r *Registry) SetBaseDir(dir string) + func (r *Registry) SetBytecode(name string, bc []byte) + func (r *Registry) SetDynamicImportTargets(targets []string) + func (r *Registry) SetDynamicModule(specifier, source string) + func (r *Registry) SetRuntimeExternals(externals []string) + func (r *Registry) SetSharedRuntime(source string) + func (r *Registry) SharedRuntime() string + func (r *Registry) TagNames() []string + func (r *Registry) Unregistered() []string + type RenderResult struct + CSS string + HTML string + TagName string