Search code examples
angularag-gridag-grid-angular

Can't bind to 'groupDisplayType' since it isn't a known property of 'ag-grid-angular'


I am trying to bind groupDisplayType property but it looks like the property has been dropped in the recent version of Ag-Grid. I am using 25.1.0.

<ag-grid-angular
    [columnDefs]="columnDefs"
    [groupDisplayType]="groupDisplayType"
    /* other grid options ... */>
</ag-grid-angular>

Error:

NG8002: Can't bind to 'groupDisplayType' since it isn't a known property of 'ag-grid-angular'.
1. If 'ag-grid-angular' is an Angular component and it has 'groupDisplayType' input, then verify that it is part of this module.
2. If 'ag-grid-angular' is a Web Component then add 'CUSTOM_ELEMENTS_SCHEMA' to the '@NgModule.schemas' of this component to suppress this message.
3. To allow any property add 'NO_ERRORS_SCHEMA' to the '@NgModule.schemas' of this component.

6     [groupDisplayType]="groupDisplayType"

There are some online examples available on Ag-grid website but they seem to be using older version of ag-grid.

Is there any alternate method available to bind groupDisplayType?


Solution

  • The concept of groupDisplayType was only introduced to Ag Grid on version 26.0.0.

    You will need to upgrade to 26+ to be able to use it. When working with older versions of Ag Grid always use the documentation relevant to your version, in this case: https://www.ag-grid.com/archive/25.1.0/angular-grid/