Table

A table component for displaying structured data in rows and columns.

组件展示

Header1
Header2
Cell 1
Cell 2
Cell 1
Cell 2
Cell 1
Cell 2
Cell 1
Cell 2
Cell 1
Cell 2

属性

属性名
类型
必需性
描述
id*
ComponentId
必需
暂无描述
accessibility
AccessibilityAttributes
可选
暂无描述
styles
Styles
可选
Component style properties
weight
number
可选
The relative weight of this component within a Row or Column. This is similar to the CSS 'flex-grow' property. Note: this may ONLY be set when the component is a direct descendant of a Row or Column.
component*
"Table"
必需
暂无描述
columns
string[]
可选
Array of column header names. Defines the column titles of the table.
rows*
string[][]
必需
Array of table data rows. Each row is a string array containing the data for each column in that row.

代码示例

{
  "component": "Table",
  "id": "table_1",
  "rows": "示例rows"
}