DeeboData Angular Grid JS Grid
Contact Us Demo Pricing

DeeboData Angular Datagrid Using RxJS

Angular Data Grid

The use of the RxJS library is the only 3rd party npm package any of our data grids use.

Angular packages.json file
We pride ourselves on creating first party solutions. Learn about how we use the one 3rd party package our grid depends on, RxJS. We will try to cover a potential issue here proactively so you don't have to go searching for answers if your compiler complains.

As you can see in the image above on line 31, the project you download if you choose us defaults to RxJS version ~7.8.0. This allows our code to pass multiple callback arguments (we only pass 1) to the .subscribe method like pictured below on line 175:

ngoninit code


Depending on your existing project setup or the version of RxJS that you install, the .subscribe method may expect different argument(s). There are 14 instances of the .subscribe method being used in the Angular Data Grid code, and if your version of RxJS expects 1 object with callback functions as the next, error, complete properties, you will get a compiler error. If that happens, simply change the code to follow the below api:

this.dataTableService.getSampleData().subscribe({
   next: (val) => console.log('Received:', val),
   error: (err) => console.error('Error occurred:', err),
   complete: () => console.log('Done!')
});


Then simply pass the 1 callback function our default code uses as the function given to the next property.