erroroverlay

package
v4.2.0 Latest Latest
Warning

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

Go to latest
Published: Jul 5, 2026 License: MIT Imports: 2 Imported by: 0

Documentation

Overview

Package erroroverlay renders an Elm-grade, in-page error overlay as a GoWebComponents component (FB4). It is the visual surface for a development error/diagnostic: a clear title, the message, an optional actionable hint ("here's likely how to fix it"), and an optional stack — rendered as a dismissible modal so a failure is legible in the page instead of only in the console. The structured diagnostics data already lives in the runtime/diagnostics packages; this is the dogfooded view over it.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ErrorOverlay

func ErrorOverlay(parseProps Props) ui.Node

ErrorOverlay renders the error as a dismissible, accessible modal overlay. Restyle via the gwc-error-overlay classes.

Types

type Props

type Props struct {
	// Title is the short heading (e.g. "Render error"). Defaults to "Error".
	Title string
	// Message is the primary error text.
	Message string
	// Hint is an optional actionable suggestion — the Elm-grade "try this" line.
	Hint string
	// Stack is optional call-stack / trace frames.
	Stack []string
	// OnDismiss, when set, wires the close control.
	OnDismiss func()
}

Props configures an ErrorOverlay.

func FromError

func FromError(parseErr error) Props

FromError builds overlay props from a Go error (Title defaults applied by ErrorOverlay).

Jump to

Keyboard shortcuts

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