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 🙏

© 2024 – Pkg Stats / Ryan Hefner

ng-creating-dynamic-table

v1.2.4

Published

this will help to create the dynamic table and also will allow to dynamic search and pagination.

Downloads

34

Readme

angular-creating-Dynamic-table-with pagination-and searching

Angular creating table component for web applications. Easy to integrate and use.

Getting Started

Features

  • create dynamic row and column of the table.
  • you can give default sorting by any column.
  • easily sort by any column dynamically.
  • give searching dynamic.
  • in searching you can give searching or not or default searching or search by
  • in searching there is also give the placeholder
  • there is also the pagination you can allow them or not
  • in pagination you can set up how many pages you want to show
  • in pagination there is also the select option in which you can how much items you want to show in the single page

Installation


```ts
import { DynamicTableModule } from 'ng-creating-dynamic-table';

// ...

@NgModule({
  imports: [
   DynamicTableModule
    // ...
  ]
  // ...
})
export class AppModule {}

Usage

import { Component } from '@angular/core';

export class AppComponent implements OnInit {
export class AppComponent {
  tableData: any[];
  pagination: object;
  searchData: object;
  headerData: any[];
  options: object;

  constructor() {

    this.tableData = [

   { Id: 4, FirstName: 'Narco', LastName: 'agrawal', email: '[email protected]' },
      { Id: 2, FirstName: 'Bombasto', LastName: 'sharma', email: '[email protected]' },
      { Id: 34, FirstName: 'Celeritas', LastName: 'asdasd', email: '[email protected]' },
      { Id: 44, FirstName: 'Magneta', LastName: 'verma', email: '[email protected]' },
      { Id: 5, FirstName: 'RubberMan', LastName: 'asdasd', email: '[email protected]' },
      { Id: 644, FirstName: 'Dynama', LastName: 'mandoi', email: '[email protected]' },
      { Id: 7, FirstName: 'Dr IQ', LastName: 'mandoi', email: '[email protected]' },
      { Id: 64, FirstName: 'Dynama', LastName: 'asdasd', email: '[email protected]' },
      { Id: 7, FirstName: 'Dr IQ', LastName: 'asdasd', email: '[email protected]' },
      { Id: 84, FirstName: 'Magma', LastName: 'asdasd', email: '[email protected]' },
      { Id: 92, FirstName: 'Tornado', LastName: 'asdasd', email: '[email protected]' },
      { Id: 64, FirstName: 'Dynama', LastName: 'mandoi', email: '[email protected]' },
      { Id: 7, FirstName: 'Dr IQ', LastName: 'mandoi', email: '[email protected]' },
      { Id: 64, FirstName: 'Dynama', LastName: 'asdasd', email: '[email protected]' },
      { Id: 7, FirstName: 'Dr IQ', LastName: 'asdasd', email: '[email protected]' },
      { Id: 84, FirstName: 'Magma', LastName: 'asdasd', email: '[email protected]' },

    ];
    this.pagination = {

      isPagination: false,// this is for allow paginatin
      showEntries: [3, 4], // how many items you want to show on per page 
     

    };
    this.searchData = {
      'isSearching': true,// this is for if you want to search allow
      'searchBy': ['FirstName', 'LastName'], // this is for choice  by the column name searching
      'searchTitle': 'search by  name or lastName', // this is the placeholder which you want to show
      'noRecord': 'no record found' // this is for the msg if records does not found
    };
    this.headerData = [
      {
        'columnName': 'FirstName',// this is for the columnname   data
        'sortBy': 'FirstName',// this option for the givin sorting by column name
        'isSorting': true, // this is for the sorting i you want to sort true
        'keyName': 'FirstName', // this is for the arranging the column data and row data in same place
        'defaultSorting': 'FirstName' // this is for default sorting
      },
      {
        'columnName': 'Ids',
        'sortBy': 'Id',
        'isSorting': true,
        'keyName': 'Id',
      },
      {
        'columnName': 'LastName',
        'sortBy': 'LastName',
        'isSorting': true,
        'keyName': 'LastName',
      },
      {
        'columnName': 'email',
        'sortBy': 'email',
        'isSorting': true,
        'keyName': 'email',
      }
     
     
    ];
    this.options = {

      headerData: this.headerData, // this is for the header of the table
      tableData: this.tableData,// this is for the data of the table
      footerData: true,//this will show the footer of the table    i you allow true and if you give false then it will remove
      searchData: this.searchData,// this is for search data into table
      pagination: this.pagination // this is for the pagination
    };
  }

//this is for the to get the value of the row of table
  receiveRowValue(event) {
    console.log(event);
  }

}  
 

```html

<ng-dynamic-Table [options] = options  (changeEvent)="receiveRowValue($event)"></ng-dynamic-Table> 


## Run locally

* Clone the repository or downlod the .zip,.tar files.
* Run `npm install`
* Run `ng serve` for a dev server
* Navigate to `http://localhost:4200/`

## Library Build / NPM Package

Run `yarn build:lib` to build the library and generate an NPM package. The build artifacts will be stored in the dist-lib/ folder.

## Running unit tests

Run `yarn test` to execute the unit tests.

## Development

This project was generated with Angular CLI version 1.7.1.

## Contributions

Contributions are welcome, please open an issue and preferrably file a pull request.

### Opening Issue

Please share sample code using codesandbox.com or stackblitz.com to help me re-produce the issue.

## License

MIT License.