package json
import "cuelang.org/go/internal/encoding/json"
Index ¶
Functions ¶
func Encode ¶
Encode converts a CUE AST to unescaped JSON.
The given file must only contain values that can be directly supported by JSON:
Type Restrictions BasicLit File no imports, aliases, or definitions StructLit no embeddings, aliases, or definitions List Field must be regular; label must be a BasicLit or Ident
Comments and attributes are ignored.
func Marshal ¶
Marshal is a replacement for json.Marshal without HTML escaping.
Source Files ¶
encode.go
- Version
- v0.6.0-alpha.1
- Published
- Apr 12, 2023
- Platform
- js/wasm
- Imports
- 10 packages
- Last checked
- 1 hour ago –
Tools for package owners.