# uni-grid
## Instructions
组件名:uni-grid
代码块: uGrid
点击下载&安装
### Syntax
- 使用 ``(或 ``,当需要包裹子节点时)。
- 遇到平台差异时,建议使用条件编译(`#ifdef / #endif`)显式处理。
#### Properties
| 属性名 | 类型 | 默认值 | 说明 |
| --- | --- | --- | --- |
| column | Number | 3 | 每列显示个数 |
| borderColor | String | #d0dee5 | 边框颜色 |
| showBorder | Boolean | true | 是否显示边框 |
| square | Boolean | true | 是否方形显示 |
| highlight | Boolean | true | 点击背景是否高亮 |
#### Events
| 事件名 | 说明 | 返回值 |
| --- | --- | --- |
| @change | 点击 grid 触发 | e={detail:{index:0}},index 为当前点击 grid下标 |
#### Platform Compatibility
See official docs for platform support table: `https://uniapp.dcloud.net.cn/component/uniui/uni-grid.html`
### Examples
### Example (Example 1)
```vue
文本
文本
文本
```
### Example (Example 2)
```html
文本
文本
文本
```
### Example (Example 3)
```vue
文本
文本
文本
文本
文本
文本
```
### Example (Example 4)
```html
文本
文本
文本
文本
文本
文本
```
### Example (Example 5)
```vue
宫格组件主要使用场景如:商品推荐列表、热门内容等
文本信息
文本信息
{{ item.text }}
{{ item.text }}
{{ item.text }}
{{ item.text }}
{{item.text}}
{{ item.text }}
```
### Example (Example 6)
```html
宫格组件主要使用场景如:商品推荐列表、热门内容等
文本信息
文本信息
{{ item.text }}
{{ item.text }}
{{ item.text }}
{{ item.text }}
{{item.text}}
{{ item.text }}
```
Reference:
- [Official Documentation](https://uniapp.dcloud.net.cn/component/uniui/uni-grid.html)
- [Plugin Marketplace](https://ext.dcloud.net.cn/plugin?name=grid)
- [Local Example](examples/uni-ui/uni-grid.vue)