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

v0 state

Back to all declarations

maxResults

untyped bigint

maxResults caps how many completions a single Render lists.

Value

(25 <untyped> bigint)

dictionary

[]string (len=55)

dictionary is the demo corpus: gno/Go vocabulary, deliberately clustered on a few prefixes ("co", "gn", "re", "tr") so completions are fun to explore.

Open
OID
0787f3…8778:4
dictionary details (len=55)

+55 more Inspect slice

dict

*v0.Trie

dict is built once at init; the library keeps it sorted internally.

Open
OID
0787f3…8778:6
dict details

Inspect pointer

Render

func(path string) string

Render renders the autocomplete for gnoweb. Render("") / Render("/") -> the whole dictionary + usage Render("/<prefix>") -> every word completing <prefix>

Open
OID
0787f3…8778:775
Render details

Inspect func

parsePrefix

func(path string) string

parsePrefix extracts the prefix from a Render path like "/gno", keeping only the first segment. Returns "" for the empty/root path.

Open
OID
0787f3…8778:777
parsePrefix details

Inspect func

list

func(words []string) string

list renders words as a Markdown bullet list.

Open
OID
0787f3…8778:778
list details

Inspect func
maxResults : untyped bigint =(25 <untyped> bigint)
dictionary : []string (len=55) Inspect
dict : *v0.Trie Inspect
Render : func(path string) string Inspect
parsePrefix : func(path string) string Inspect
list : func(words []string) string Inspect