{
  "classes": [
    {
      "constants": [],
      "types": [
        {
          "lua_type": "type EncodeOptions = {\n    indent: string?,\n    sortKeys: boolean?,\n    flowLevel: number?,\n}",
          "name": "EncodeOptions",
          "tags": [],
          "source": {
            "path": "",
            "line": 156
          },
          "fields": [
            {
              "lua_type": "indent: string?",
              "name": "indent",
              "desc": "Indentation string (default `\"  \"` - two spaces)."
            },
            {
              "lua_type": "sortKeys: boolean?",
              "name": "sortKeys",
              "desc": "Sort mapping keys alphabetically."
            },
            {
              "lua_type": "flowLevel: number?",
              "name": "flowLevel",
              "desc": "Use flow (inline) style for nested structures."
            }
          ],
          "desc": ""
        }
      ],
      "name": "@eryx/encoding/yaml",
      "tags": [],
      "functions": [
        {
          "source": {
            "path": "",
            "line": 316
          },
          "is_method": false,
          "signature": "yaml.encode(\n    value: any,  -- -- The value to encode.\n    options: EncodeOptions?  -- Optional formatting options.\n) → (\n    string  -- The YAML string. \n)",
          "owner": "yaml",
          "desc": "Encodes a Luau value as a YAML string.\n\nTables with sequential integer keys (1 .. n) are encoded as YAML sequences.\nTables with string keys are encoded as YAML mappings. Nested structures\nare fully supported.\n\n```luau\nlocal yaml = require(\"@eryx/encoding/yaml\")\nprint(yaml.encode({ a = 1, b = { 2, 3 } }))\n-- a: 1\n-- b:\n--   - 2\n--   - 3\n```\n",
          "tags": [],
          "name": "encode",
          "return_str": "string",
          "function_type": "Function",
          "returns": [
            {
              "lua_type": "string",
              "desc": "The YAML string. "
            }
          ],
          "params": [
            {
              "lua_type": "any",
              "name": "value",
              "desc": "-- The value to encode."
            },
            {
              "lua_type": "EncodeOptions?",
              "name": "options",
              "desc": "Optional formatting options."
            }
          ]
        },
        {
          "source": {
            "path": "",
            "line": 1216
          },
          "is_method": false,
          "signature": "yaml.decode(\n    str: string  -- A valid YAML string.\n) → (\n    any  -- The decoded Luau value. \n)",
          "owner": "yaml",
          "desc": "Decodes a YAML string into a Luau value.\n\nSupports block and flow scalars/sequences/mappings, multi-line strings\n(literal `|` and folded `>`), anchors/aliases, and YAML 1.2 core schema\ntype resolution.\n\nOnly the first document is parsed when `---` separators are present.\n\n```luau\nlocal yaml = require(\"@eryx/encoding/yaml\")\nlocal config = yaml.decode([[\nname: My App\nversion: 1.2\nfeatures:\n  - auth\n  - logging\n]])\nprint(config.name)  -- \"My App\"\n```\n",
          "tags": [],
          "name": "decode",
          "return_str": "any",
          "function_type": "Function",
          "returns": [
            {
              "lua_type": "any",
              "desc": "The decoded Luau value. "
            }
          ],
          "params": [
            {
              "lua_type": "string",
              "name": "str",
              "desc": "A valid YAML string."
            }
          ]
        }
      ],
      "properties": [],
      "source": {
        "path": "",
        "line": 0
      },
      "desc": "YAML encoding and decoding.\n\nSerialises Luau values to YAML text and parses YAML text back into\nLuau values.  Supports a practical subset of YAML 1.2 (block scalars,\nblock/flow sequences and mappings, anchors & aliases, multi-line strings).\n\n```luau\nlocal yaml = require(\"@eryx/encoding/yaml\")\n\nlocal str = yaml.encode({ name = \"Alice\", scores = {100, 97} })\nprint(str)\n-- name: Alice\n-- scores:\n--   - 100\n--   - 97\n\nlocal tbl = yaml.decode(\"x: 1\\ny: 2\")\nprint(tbl.x, tbl.y)  -- 1  2\n```\n\n**Mapping rules:**\n\n| Luau          | YAML             |\n|---------------|------------------|\n| `string`      | scalar           |\n| `number`      | scalar (numeric) |\n| `boolean`     | true / false     |\n| `nil`         | null / ~         |\n| Numeric table | sequence (- ...) |\n| Mixed table   | mapping (k: v)   |\n"
    }
  ]
}