Help us shape the future of Go! Take the 2026 Go Developer Survey

compactyaml

package
v0.3.308 Latest Latest
Warning

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

Go to latest
Published: Nov 2, 2026 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Marshal

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

Marshal serializes a JSON-marshalable object into deterministic compact YAML.

Following Kubernetes conventions (consistent with sigs.k8s.io/yaml and bobctl), serialization routes through a JSON intermediate representation so that standard `json:"..."` struct tags and Kubernetes schema definitions are preserved. As a consequence, inputs are restricted to JSON-marshalable objects; YAML-specific struct tags (`yaml:"..."`) and yaml.Marshaler implementations are not evaluated.

Types

This section is empty.

Jump to

Keyboard shortcuts

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