Documentation
¶
Index ¶
- type AttrHook
- type Cinema
- type ClientCall
- type Core
- type Done
- type Door
- func (n *Door) Clear(ctx context.Context)
- func (n *Door) Reload(ctx context.Context)
- func (n *Door) Remove(ctx context.Context)
- func (n *Door) Render(ctx context.Context, w io.Writer) error
- func (n *Door) Replace(ctx context.Context, content templ.Component)
- func (n *Door) Update(ctx context.Context, content templ.Component)
- func (n *Door) XClear(ctx context.Context) <-chan error
- func (n *Door) XReload(ctx context.Context) <-chan error
- func (n *Door) XRemove(ctx context.Context) <-chan error
- func (n *Door) XReplace(ctx context.Context, content templ.Component) <-chan error
- func (n *Door) XUpdate(ctx context.Context, content templ.Component) <-chan error
- type DoorHook
- type Hook
- type HookEntry
- type Root
- type RootRender
- type Screen
- type Watcher
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Cinema ¶
type Cinema struct {
// contains filtered or unexported fields
}
func (*Cinema) AddWatcher ¶
type ClientCall ¶
type Door ¶
type Door struct { Tag string A templ.Attributes // contains filtered or unexported fields }
func (*Door) Clear ¶
Clear removes all content from the door, equivalent to Update(ctx, nil). The door's DOM element remains but its children are removed. This is useful for emptying a container while keeping it available for future content.
func (*Door) Reload ¶
Reload re-renders the door with its current content. This is useful when you want to refresh a door without changing its content, for example to reflect external state changes. If the door is not currently active, the operation completes immediately without visual effect.
func (*Door) Remove ¶
Remove removes the door and its DOM element from the page. If the door is not currently active, it is marked as removed and will not render if attempted to be rendered.
func (*Door) Replace ¶
Replace replaces the entire door element with new content. Unlike Update, this removes the door's DOM element entirely and replaces it with the rendered content. If the door is not currently active, the content change is stored and will be applied when the door is rendered.
func (*Door) Update ¶
Update changes the content of the door and re-renders it in place. The door's children are replaced with the new content while preserving the door's DOM element. If the door is not currently active, the content change is stored and will be applied when the door is rendered.
func (*Door) XClear ¶
XClear returns a channel that can be used to track when the clear operation completes. The channel will receive nil on success or an error if the operation fails. The channel is closed after sending the result. If the door is not active, the channel is closed immediately without sending any value. This is equivalent to XUpdate(ctx, nil) and empties the door's content.
func (*Door) XReload ¶
XReload returns a channel that can be used to track when the reload operation completes. The channel will receive nil on success or an error if the operation fails. The channel is closed after sending the result. If the door is not active, the channel is closed immediately without sending any value. A blocking context warning is logged if called from a blocking context.
func (*Door) XRemove ¶
XRemove returns a channel that can be used to track when the remove operation completes. The channel will receive nil on success or an error if the operation fails. The channel is closed after sending the result. If the door is not active, the channel is closed immediately without sending any value. A blocking context warning is logged if called from a blocking context.
func (*Door) XReplace ¶
XReplace returns a channel that can be used to track when the replace operation completes. The channel will receive nil on success or an error if the operation fails. The channel is closed after sending the result. If the door is not active, the channel is closed immediately without sending any value. A blocking context warning is logged if called from a blocking context.
func (*Door) XUpdate ¶
XUpdate returns a channel that can be used to track when the update operation completes. The channel will receive nil on success or an error if the operation fails. The channel is closed after sending the result. If the door is not active, the channel is closed immediately without sending any value. A blocking context warning is logged if called from a blocking context.
type RootRender ¶
type RootRender struct {
// contains filtered or unexported fields
}
func (*RootRender) Err ¶
func (r *RootRender) Err() error
type Screen ¶
type Screen struct {
// contains filtered or unexported fields
}