npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

ngx-elastic-datatable

v0.1.7

Published

[![Version](http://img.shields.io/npm/v/ngx-elastic-datatable.svg)](https://www.npmjs.org/package/ngx-elastic-datatable)

Readme

Angular Elastic DataTable Component

Version

A minimalist DataTable-based component for Angular with elastic pagination.

Installation

npm install ngx-elastic-datatable --save

Usage

Import the ElasticDatatable Module and add it to the imports of your application module.

import { ElasticDatatableModule } from 'ngx-elastic-datatable'

@NgModule({
  imports: [ ElasticDatatableModule ],
  declarations: [ ... ],
  bootstrap: [ ... ]
})
export class YourModule { }

Call the component from within a template.

  <ngx-elastic-datatable  [config]="config"
                          [items]="data"
                          [columns]="columns"
                          [currentPage]="page"
                          [filterString]="searchFilter"
                          [filterGroupId]="selectedGroupId"
                          (didSelectedRow)="didSelectedRow($event);"
                          (didChangedTotalPages)="didChangedTotalPages($event);"></ngx-elastic-datatable>

And you're set!

API

The elastic datatable component has an emitter named didSelectedRow launched when a row is selected, and also has an emitter named didChangedTotalPages launched when the datatable has recalculated the number of rows to show per page (mainly due to browser window resize).

The elastic datatable component should be called with the parameters listed below.

| Parameter | Type | Description | |---|---|---| | items | array | An array of groups with lists of rows. | | columns | array | An array describing the columns of the datatable. | | config | array | An array with the configuration of the datatable. | | currentPage | number | The page number to be shown in the datatable. | | filterString | string | Text to be filtered in the datatable rows. | | filterGroupId | string | The group id to be filtered in the datatable rows. |

Example of data structure to be used as items parameter:

public data: Array<any> = [
  {
    'id': '1',
    'name': 'Area 1',
    'groupHeaderClassName': 'context-list-subheader',
    'rows':
      [{
        'id': '128',
        'num': '128',
        'name': 'Masferrer Serrat Albert',
        'hours': '35h',
        'selected': true
      }, {
        'id': '244',
        'num': '244',
        'name': 'Puig Guitart Sílvia',
        'hours': '22h',
        'selected': false
      }, {
        'id': '432',
        'num': '432',
        'name': 'Masferrer Puig Pau',
        'hours': '24h',
        'selected': false
      }, {
        'id': '784',
        'num': '784',
        'name': 'Masferrer Pellisser Carlos',
        'hours': '28h',
        'selected': false
      }]
  },
  {
    'id': '2',
    'name': 'Area 2',
    'groupHeaderClassName': 'context-list-subheader',
    'rows':
      [{
        'id': '264',
        'num': '264',
        'name': 'Serrat Comas Montserrat',
        'hours': '21h',
        'selected': false
      }, {
        'id': '841',
        'num': '841',
        'name': 'Masferrer Serrat Laura',
        'hours': '25h',
        'selected': false
      }, {
        'id': '472',
        'num': '472',
        'name': 'Serrat Oltra Salvador',
        'hours': '29h',
        'selected': false
      }, {
        'id': '548',
        'num': '548',
        'name': 'Serrat Oltra Alba',
        'hours': '20h',
        'selected': false
      }, {
        'id': '328',
        'num': '328',
        'name': 'Serrat Comas Jaume',
        'hours': '23h',
        'selected': false
      }]
  }];

Example of data structure to be used as columns parameter:

  public columns:Array<any> = [
    {
        title: 'NÚM',
        name: 'num',
        headerClassName: 'employee-list-fields-num',
        cellClassName: 'employee-list-item-num'
    }, {
        title: 'NOMBRE',
        name: 'name',
        headerClassName: 'employee-list-fields-name',
        cellClassName: 'employee-list-item-name'
    }, {
        title: 'H',
        name: 'hours',
        headerClassName: 'employee-list-fields-hours',
        cellClassName: 'employee-list-item-hours'
    }
  ];

Example of data structure to be used as config parameter:

  public config:any = {
    paging: true,
    sorting: {columns: this.columns},
    filtering: { filterString: '',
		 columnName: 'name' },
    groupSelectorPlaceholder: 'Filtrar por estructura o organización'
  };

License

MIT