Search Apps Documentation Source Content File Folder Download Copy Actions Download State String Boolean Number Struct Map Slice Pointer Function Closure Reference Nil Package Type Interface Unknown

home package

Overview

Package home is the realm behind https://gno.land/u/clockwork.

gnoweb builds a user profile page by calling Render("") on the realm at the exact path /r/<username>/home (gno.land/pkg/gnoweb/handler_http.go, GetUserView). That lookup does no version resolution, so this path is the interface with gnoweb and can never carry a /vN suffix. Everything that might want to change therefore lives behind the path, in four layers:

  1. CONTENT is data. The page is assembled from SLOTS: named markdown fragments in an avl tree, each written by its own Set call. Updating one paragraph is one small transaction.
  2. LAYOUT is data. The slot named "layout" is the page template; every :slug: placeholder in it is filled from the slot of that name.
  3. STYLE is data. Slots under the "style." prefix are knobs (colors, header mode) that the theme reads. Changing the accent color is a Set.
  4. RENDERING is code, but replaceable. A THEME is a separate realm nested under this one that implements Theme and registers itself from its own init. The authority accepts it through p/clockwork/upgradeable and can roll it back. The slots never move: an upgrade replaces the code that reads them, not the data. When no theme is live the built-in renderer in render.gno serves the page, and the operator views (system, slots, edit, manifest) are always served by this realm, so a theme that panics can be rolled back from the page it cannot break.

This realm holds state and forwards. It is deliberately small, because it is the one piece that can never be redeployed: it is importable by its themes, so it cannot be private, so AddPackage refuses a second deploy.

Function

Slugs

func Slugs() []string

Slugs returns every slot name, sorted.

Command

gnokey query vm/qeval -remote "https://rpc.gno.land" -data "gno.land/r/g1lnkytfqcjwllws63gvf0mv9yt04aswy4y9amhm/home.Slugs()"

Result