Make great documentation goal 1.2, and plan the README's reorganisation and the nested-template gaps #33
@@ -491,8 +491,8 @@ table, `{/misc.currency[SEK].symbol}` on one row and `{/misc.currency[EUR].symbo
|
||||
on the next, since only one row renders. `New` proves the header, the options and every
|
||||
cell token, and refuses a TSV no category names, a key that is empty or repeats, a
|
||||
weight that is not a positive number, and a key or name holding `[`, `]`, `{`, `}`,
|
||||
`"` or `|`, which a selector cannot spell; the rows are indexed on the first draw that
|
||||
selects one. A `name` needs a `key`, since a name naming several rows is reported by
|
||||
`"` or `|`, which a selector cannot spell; `New` maps the keys, and the lookups by name
|
||||
and by parent wait for the first draw that selects one. A `name` needs a `key`, since a name naming several rows is reported by
|
||||
their keys, or a `parent`, inside whose row a name names one row, so `first-name[Kim]`
|
||||
is settled by the `sex` selected before it and a name repeating inside one parent row
|
||||
is refused; a name spelling another row's key is refused, since the key would
|
||||
|
||||
@@ -61,8 +61,7 @@ func loadData(sources []dataSource) (map[string]node, error) {
|
||||
return root, nil
|
||||
}
|
||||
|
||||
// loadDir compiles one directory into a folder. fs.ReadDir yields entries sorted
|
||||
// by name, so the tree is built deterministically. Empty subdirectories (no JSON
|
||||
// loadDir compiles one directory into a folder. Empty subdirectories (no JSON
|
||||
// anywhere under them) are skipped rather than added as empty namespaces.
|
||||
func loadDir(src dataSource, dir string) (*folder, error) {
|
||||
entries, err := fs.ReadDir(src.fsys, dir)
|
||||
|
||||
@@ -50,10 +50,10 @@ func (f *Generator) FakeTemplate(input string) (string, error) {
|
||||
}
|
||||
|
||||
// IsTemplate reports whether arg is an inline template rather than a path, by its shape: a {
|
||||
// token, or a JSON object, array or string, is a template, and anything else is a path. A
|
||||
// name never holds a bracket, a brace or a quote, so an arg holding one that is not valid
|
||||
// JSON names neither, and errors; so do a template of one reference alone, which is a path
|
||||
// written as a template, and a path written with a leading /.
|
||||
// token, or a JSON object, array or string, is a template, and anything else is a path. An
|
||||
// arg that is not valid JSON errors where it holds a } or a quote, or starts with [, since no
|
||||
// path may; so do a template of one reference alone, which is a path written as a template,
|
||||
// and a path written with a leading /.
|
||||
func IsTemplate(arg string) (bool, error) {
|
||||
inline, err := isTemplate(arg)
|
||||
if err != nil {
|
||||
|
||||
@@ -40,11 +40,6 @@ maintainer chose on 2026-09-30 to go on with the path steps regardless.
|
||||
|
||||
This round, in order:
|
||||
|
||||
- Correct the claims readers followed wrong: `IsTemplate`'s doc says an argument holding
|
||||
a bracket that is not valid JSON errors, where `misc.territory[SE]` is a path; the
|
||||
README says rows are indexed on the first draw, where `New` builds the key map; and
|
||||
`loadDir`'s says it builds the tree deterministically, where it reports an unnamed
|
||||
rows file in map order.
|
||||
- Delete the comments the panel found restating their code or arranging the file:
|
||||
`node`'s second sentence, `op`'s "compile builds these so render never re-scans the
|
||||
format", `checkCalc`'s last sentence, `calcVar.eval`'s four lines, `checkNoCycles`'
|
||||
|
||||
Reference in New Issue
Block a user