Documentation
¶
Index ¶
- func ConvertHTMLToText(html string) string
- type Template
- func (t *Template) Apply(data map[string]any) error
- func (t *Template) Close() error
- func (t *Template) ProcessLoops(data map[string]any) error
- func (t *Template) Save(path string) error
- func (t *Template) SetTextValue(placeholder, value string) error
- func (t *Template) SetTextValueHTML(placeholder, htmlValue string) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ConvertHTMLToText ¶
ConvertHTMLToText converts basic HTML to plain text for ODT Strips HTML tags and preserves content
Types ¶
type Template ¶
type Template struct {
// contains filtered or unexported fields
}
Template represents an ODT document template
func (*Template) ProcessLoops ¶
ProcessLoops handles {#arrayName}...{/arrayName} in content
func (*Template) SetTextValue ¶
SetTextValue replaces a placeholder in text with a value
func (*Template) SetTextValueHTML ¶
SetTextValueHTML replaces a placeholder with HTML content (basic support)
Click to show internal directories.
Click to hide internal directories.