mdencoder

package module
v1.0.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 11, 2025 License: Apache-2.0 Imports: 6 Imported by: 2

README

Markdown Encoder

mdecoder is a library encoding/decoding markdown to go struct


Go Reference Go goreleaser GitHub go.mod Go version of a Go module GoReportCard GitHub license GitHub release

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Marshal

func Marshal(obj any) ([]byte, error)

Marshal converts a struct instance to Markdown based on `jsonschema` tags.

Types

type Encoder

type Encoder struct {
	// contains filtered or unexported fields
}

func NewEncoder

func NewEncoder(w io.Writer) *Encoder

func (*Encoder) Encode

func (e *Encoder) Encode(obj any) error

type Marshaler

type Marshaler interface {
	MarshalMarkdown() ([]byte, error)
}

type StructMarkdownStyle

type StructMarkdownStyle int
const (
	StructMdTitleStyle StructMarkdownStyle = iota
	StructMdListStyle
	StructMdInListStyle
)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL