mirror of
https://github.com/usememos/memos.git
synced 2024-12-21 10:11:42 +03:00
88799d469c
chore: initial gomark folder
13 lines
179 B
Go
13 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)
|
|
}
|