> ## 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.object

> Real JSON encoder が object として扱う new table marked as a JSON object を作成します。

<div className="real-function-page">
  ```lua theme={null}
  json.object(source?: table): table
  ```

  ## 引数

  <ParamField path={"source"} type={"table"}>
    New object table に copy される optional source table。omitted または nil の場合、empty object table が返ります。
  </ParamField>

  ## 戻り値

  <ResponseField name={"object"} type={"table"}>
    Real JSON object marker で marked された new table。Source entries は copy されますが、Real JSON type marker は除外されます。
  </ResponseField>

  ## 例

  Empty object を含む new table marked as a JSON object を create します。

  ```lua theme={null}
  local profile = json.object({
      name = "Guest",
      active = true,
  })
  local empty = json.object()

  print(json.encode(profile))
  print(json.encode(empty))
  ```
</div>
