mirror of
https://github.com/usememos/memos.git
synced 2024-12-29 16:42:11 +08:00
88799d469c
chore: initial gomark folder
12 lines
179 B
Go
12 lines
179 B
Go
package ast
|
|
|
|
func NewNode(tp, text string) *Node {
|
|
return &Node{
|
|
Type: tp,
|
|
Text: text,
|
|
}
|
|
}
|
|
|
|
func (n *Node) AddChild(child *Node) {
|
|
n.Children = append(n.Children, child)
|
|
}
|