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 🙏

© 2025 – Pkg Stats / Ryan Hefner

ngx-dynamic-table-component

v1.1.2

Published

![npm version](https://img.shields.io/npm/v/ngx-dynamic-table-component) ![npm downloads](https://img.shields.io/npm/dm/ngx-dynamic-table-component) ![GitHub issues](https://img.shields.io/github/issues/VictorDRF02/ngx-dynamic-table) ![GitHub license](htt

Downloads

39

Readme

ngx-dynamic-table-component

npm version npm downloads GitHub issues GitHub license

ngx-dynamic-table-component is an Angular component that generates a dynamic table using Bootstrap. The component accepts an input data which can be a string[][] or a TableOptions.

Table of Contents

Features

  • Dynamic table generation using Bootstrap
  • Supports both string[][] and TableOptions inputs
  • Customizable headers, footers, and cell styles
  • Sortable columns

Installation

To install the library, run:

npm install ngx-dynamic-table-component

Usage

Import the module in your Angular application:

import { NgxDynamicTableComponent } from 'ngx-dynamic-table-component';

@NgModule({
  imports: [
    // other modules
    NgxDynamicTableComponent
  ],
  // other components, services, etc.
})
export class AppModule { }

Add the bootstrap and bootstrap-icons styles to your global styles file styles.css or styles.scss:

@import '~bootstrap/dist/css/bootstrap.min.css';
@import '~bootstrap-icons/font/bootstrap-icons.css';

Example Usage

import { Component } from '@angular/core';
import { TableOptions } from 'ngx-dynamic-table-component';

@Component({
  selector: 'app-root',
  template: `
    <ngx-dynamic-table [data]="tableData"></ngx-dynamic-table>
  `
})
export class AppComponent {
  tableData: string[][] = [
    ['Header 1', 'Header 2', 'Header 3'],
    ['Row 1 Col 1', 'Row 1 Col 2', 'Row 1 Col 3'],
    ['Row 2 Col 1', 'Row 2 Col 2', 'Row 2 Col 3']
  ];

  // Or using TableOptions
  tableOptions: TableOptions = {
    header: [
      { text: 'Header 1', sortable: true },
      { text: 'Header 2', sortable: false },
      { text: 'Header 3', sortable: true }
    ],
    body: [
      [
        { text: 'Row 1 Col 1', bold: true },
        { text: 'Row 1 Col 2' },
        { text: 'Row 1 Col 3', italic: true }
      ],
      [
        { text: 'Row 2 Col 1' },
        { text: 'Row 2 Col 2', class: 'custom-class' },
        { text: 'Row 2 Col 3' }
      ]
    ],
    footer: [
      [
        { text: 'Footer 1' },
        { text: 'Footer 2' },
        { text: 'Footer 3' }
      ]
    ],
    class: 'table-class'
  };
}

API

Inputs

  • data: string[][] | TableOptions - The data to be displayed in the table.

TableOptions

  • header: CellHeaderOptions[] - Table header content.
  • body: CellOptions[][] - Table body content.
  • footer: CellOptions[][] - Table footer contents.
  • class: string - Custom class for the table.

Examples

Basic Example

@Component({
  selector: 'app-basic',
  template: `
    <ngx-dynamic-table [data]="basicData"></ngx-dynamic-table>
  `
})
export class BasicComponent {
  basicData: string[][] = [
    ['Header 1', 'Header 2', 'Header 3'],
    ['Row 1 Col 1', 'Row 1 Col 2', 'Row 1 Col 3']
  ];
}

Advanced Example with TableOptions

@Component({
  selector: 'app-advanced',
  template: `
    <ngx-dynamic-table [data]="advancedOptions"></ngx-dynamic-table>
  `
})
export class AdvancedComponent {
  advancedOptions: TableOptions = {
    header: [
      { text: 'Header 1', sortable: true },
      { text: 'Header 2', sortable: false },
      { text: 'Header 3', sortable: true }
    ],
    body: [
      [
        { text: 'Row 1 Col 1', bold: true },
        { text: 'Row 1 Col 2' },
        { text: 'Row 1 Col 3', italic: true }
      ],
      [
        { text: 'Row 2 Col 1' },
        { text: 'Row 2 Col 2', class: 'custom-class' },
        { text: 'Row 2 Col 3' }
      ]
    ],
    footer: [
      [
        { text: 'Footer 1' },
        { text: 'Footer 2' },
        { text: 'Footer 3' }
      ]
    ],
    class: 'table-class'
  };
}

Support

If you encounter any issues or have questions, please open an issue on GitHub.

More Information

For more details, contributions, and license information, please visit the GitHub repository.