# Dynamic Columns Generation

The Kendo UI for Vue Grid allows the user to dynamically update the columns inside the component. You can dynamically change the number of the Grid columns using a computed property that returns the new columns' definition:

```jsx
columns() {
    const columns = [
    {
        field: "id",
        width: "150px",
    },
    ];
    for (let c = 1; c < this.numberOfColumns; c++) {
    columns.push({
        field: "Field-" + c.toString(),
        width: "150px",
    });
    }
    return columns;
}
```

[Demo Source](https://demos.telerik.com/kendo-vue-ui/grid/columns/dynamic-column-generation/source.txt)

## Suggested Links

* [API Reference of the Grid](https://www.telerik.com/kendo-vue-ui-develop/components/grid/api/gridprops)
* [API Index of the Grid](https://www.telerik.com/kendo-vue-ui-develop/components/grid/api)
