src/yaml

loadYaml

Load a Kubernetes object from YAML.

Parameters

data - The YAML string to load.

opts - Optional YAML load options.

returns

The deserialized Kubernetes object.

function loadYaml<T>(data: string, opts?: yaml.LoadOptions): T 

loadAllYaml

Load all Kubernetes objects from YAML.

Parameters

data - The YAML string to load.

opts - Optional YAML load options.

returns

An array of deserialized Kubernetes objects.

function loadAllYaml(data: string, opts?: yaml.LoadOptions): any[] 

dumpYaml

Dump a Kubernetes object to YAML.

Parameters

object - The Kubernetes object to dump.

opts - Optional YAML dump options.

returns

The YAML string representation of the serialized Kubernetes object.

function dumpYaml(object: any, opts?: yaml.DumpOptions): string 
Start typing to search the documentation Press ESC to close