Skip to content

Support struct fields documentation #1987

@zolotov

Description

@zolotov

Definition:

// TemplateNode represents a {{template}} action.
type TemplateNode struct {
    NodeType
    Pos
    tr   *Tree
    Line int       // The line number in the input. Deprecated: Kept for compatibility.
    Name string    // The name of the template (unquoted).
    Pipe *PipeNode // The command to evaluate as dot for the template.
}

Usage:

func (t *TemplateNode) String() string {
    if t.P<caret>ipe == nil {
        return fmt.Sprintf("{{template %q}}", t.Name)
    }
    return fmt.Sprintf("{{template %q %s}}", t.Name, t.Pipe)
}

Should show The command to evaluate as dot for the template.

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions