> ## Documentation Index
> Fetch the complete documentation index at: https://docs.projectreal.gg/llms.txt
> Use this file to discover all available pages before exploring further.

# json.unescape

> escaped string content または complete quoted JSON string literal から JSON string escape sequences をデコードします。入力は full JSON document ではなく JSON string parser で parse されます。

<div className="real-function-page">
  ```lua theme={null}
  json.unescape(text: string): string
  ```

  ## 引数

  <ParamField path={"text"} type={"string"} required>
    Escaped JSON string content、または first and last bytes が quotes の complete quoted JSON string literal。function はこの argument を string type checking で読みます。
  </ParamField>

  ## 戻り値

  <ResponseField name={"text"} type={"string"}>
    Decoded string。Supported escapes は "、\、/、\b、\f、\n、\r、\t、surrogate-pair handling 付きの \uXXXX です。Invalid escapes、unescaped control characters、unterminated strings、quoted literal 後の trailing characters は near-position suffix 付きの Luau error を投げます。
  </ResponseField>

  ## 例

  escaped content または quoted JSON string literal から JSON string escapes をデコードします。

  ```lua theme={null}
  local escaped = json.escape("Real Docs" .. string.char(10) .. "Docs")
  local restored = json.unescape(escaped)

  print(restored)
  ```
</div>
