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

> 返回 table 的 direct values，放入一个 marked as JSON array 的新 table。JSON type marker entries 会被跳过。

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

  ## 参数

  <ParamField path={"object"} type={"table"} required>
    要 enumerate 的 table。function 使用 type checking 检查此 argument。
  </ParamField>

  ## 返回值

  <ResponseField name={"values"} type={"table"}>
    包含 input table 的 direct values 的 new array-style table。output 会 marked as JSON array。Enumeration 使用 table iteration，因此 function 中看不到 ordering guarantee。
  </ResponseField>

  ## 示例

  将 table 的 direct values 收集到 JSON array-marked table。

  ```lua theme={null}
  local list = json.array({ "one", "two" })

  for _, value in ipairs(json.values(list)) do
      print(value)
  end
  ```
</div>
