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

@agentsmith.bgd/dynamic-table-lib

v0.0.39

Published

Dynamic table component

Readme

DynamicTableLib

Dynamic table component

Attributes

| Attribute | Type | Description | |-----------------------------------------|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|----------------------------------------------------------------------------------------------| | loading=false | boolean | If data are currently loading. Shows spinner if true and dim the table | | striped=false | boolean | Add table-stripped class | | bordered=false | boolean | Add table-bordered class | | hovered=false | boolean | Add table-hovered class | | enableSearch=false | boolean | Enables search field | | rowCounter=false | boolean | Add first column as row counter | | enableLog=false | boolean | Enable console logger (developer logs) | | perPage=0 | number | Offset for table pagination | | page=0 | number | Current page (active page) | | totalItems=0 | number | Total items in page | | tableHeadStorageKeyName=null | string | Total items in page | | tableStyle="" | "" or "table-light" or "table-dark" | If key name is set, column chooser is enabled and new layout will be saved to localStorage | | headStyle="table-default" | "table-default" or "table-primary" or "table-secondary" or "table-success" or "table-danger" or "table-warning" or "table-info" or "table-light" or "table-dark" | Style of the table header | | paginationAlignment="" | "" or "justify-content-center" or "justify-content-end" | Aligment of pagination component left(default), center or right | | perPageValues!:=[10, 20, 50, 100] | number[] | Displays dropdown with page offset chooser | | headerActions!:=[] | IActionButton[] | CTA buttons in table header | | rowActions!:=[] | IActionButton[] | CTA buttons in each table row | | tableHead!:=null | ITableHead[] | Setup of the table. Columns are created, and key is used to access data values | | tableData!:=null | Record<string, never>[] | Table data. Array of objects where key coresponds to tableHead key |

Events

| Event | Description | |-------------------------------------------------------------------------------------------------------------|-----------------------------------------------------------------------| | pageChange(page):EventEmitter<number> | Dispatch when we click on pagination buttons and emits target page | | filterChanged(IFilter):EventEmitter<IFilter> | Dispatch when some display or filtering option is changed | | editRow(Record):EventEmitter<Record<string, never>> | Dispatch when some row action button is clicked | | sliderClicked(Record):EventEmitter<Record<string, never>> | Dispatch when some slider is clicked in row | | headerActionClicked(actionname):EventEmitter<string> | Dispatch when header action is clicked emitting action name | | rowActionClicked({ action: actionName; value: rowData }):EventEmitter<{ action: string; value: any }> | Dispatch when row action is clicked emitting action name and row data |

Installation

Install dynamictable-lib from npm

npm i @agentsmith.bgd/dynamictable-lib

Add package to NgModule imports:

import { DynamicTableLibModule } from '@agentsmith.bgd/dynamictable-lib';

@NgModule({
	...
	imports: [DynamicTableLibModule, ...],
	...
})

Add component to your page

rowActions: IActionButton[] = [
{ actionName: 'edit', btnColor: 'btn-primary', faIcon: 'fa-edit' },
{ actionName: 'options', btnColor: 'btn-success', faIcon: 'fa-cogs' },
{ actionName: 'delete', btnColor: 'btn-danger', faIcon: 'fa-times' },
];
tableHead: ITableHead[] = [
{ key: 'id', label: 'ID', mandatory: true },
{ key: 'name', label: 'Name' },
{ key: 'email', label: 'Email' },
{ key: 'gender', label: 'Gender' },
{ key: 'company', label: 'Company' },
{ key: 'age', label: 'Age', hidden: true },
];
tabledata = [
{
name: 'Ethel Price',
email: 'Ethel [email protected]',
gender: 'female',
company: 'Johnson, Johnson and Partners, LLC CMP DDC',
age: 22,
},
{
name: 'Claudine Neal',
email: 'Claudine [email protected]',
gender: 'female',
company: 'Sealoud',
age: 55,
}
<as-dynamic-table
  (pageChange)="pageChange($event)"
  (filterParamsChanged)="sortChanged($event)"
  [bordered]="true"
  [rowCounter]="true"
  [headStyle]="'table-success'"
  [headerActions]="headerActions"
  [hovered]="true"
  [page]="0"
  [perPage]="15"
  [rowActions]="rowActions"
  [striped]="false"
  [tableData]="tableData"
  [tableHeadStorageKeyName]="'someKey'"
  [tableHead]="tableHead"
  [totalItems]="totalItem"
></as-dynamic-table>

Compatibility

There is only one dependency: Angular > 12.x.x