swimlane / ngx-datatable

✨ A feature-rich yet lightweight data-table crafted for Angular
http://swimlane.github.io/ngx-datatable/
MIT License
4.63k stars 1.68k forks source link

Property 'push' does not exist on type '{}' #1256

Open La210889 opened 6 years ago

La210889 commented 6 years ago

Build error "Property 'push' does not exist on type '{}' " occurring in datatable.component.ts at the below code

originalArray.forEach((item: any) => { const key = item[groupBy]; if (!map.has(key)) { map.set(key, [item]); } else { map.get(key).push(item); } i++; });

Using,

Angular 4 @swimlane/ngx-datatable 11.1.7 Visual Studio 2015 Update 3 Typescript 2.4.1

Can anyone help me on this?

Matmo10 commented 6 years ago

Set a breakpoint and see what key is when the error occurs.