IgniteUI / igniteui-angular

Ignite UI for Angular is a complete library of Angular-native, Material-based Angular UI components with the fastest grids and charts, Pivot Grid, Dock Manager, Hierarchical Grid, and more.
https://www.infragistics.com/products/ignite-ui-angular
Other
569 stars 162 forks source link

[Elements]: autoGenerate does not override columns declared in markup #14260

Closed RivaIvanova closed 1 month ago

RivaIvanova commented 4 months ago

Description

When set to true, the autoGenerate property in igniteui-angular overrides all columns declared through code or in markup as stated in the API docs. When used in WebComponents/React/Blazor the declared columns persist.

Steps to reproduce

  1. Define a grid that has autoGenerate set to true.
  2. Define a column in the markup.
<igc-grid auto-generate="true" id="grid">
    <igc-column field="ID"></igc-column>
</igc-grid>
private data: any[] = [
    { ID: 1, Product: "Chai", Category: "Beverages" },
    { ID: 2, Product: "Chang", Category: "Food" },
    { ID: 3, Product: "Tofu", Category: "Food" }
];

constructor() {
    const grid = document.getElementById("grid") as IgcGridComponent;
    grid.data = this.data;
}

Result

Only the defined ID column is rendered.

Expected result

The columns should be generated based on the provided data, i.e., three columns (ID, Product, Category) should be rendered.

github-actions[bot] commented 2 months ago

There has been no recent activity and this issue has been marked inactive.

ddaribo commented 1 month ago

Closing - ref to this and this comments.