@christophhu/ngx-datatable
v20.3.1
Published
Library for Angular to create data tables.
Downloads
9
Readme
Ngx-datatable
Demo
Description
This repository contains an Angular 20 demo that showcases the ngx-datatable library. ngx-datatable provides a flexible table for Angular apps. It’s easy to customize—sizes, colors, and behavior—to match your application’s design.
Frameworks and Languages
Installation
To run this project, you need to have Node.js installed on your machine. Clone the repository and run the following commands:
npm install @christophhu/ngx-datatableUsage
Import the DatatableComponent in the app.ts.
import { DatatableComponent } from '@christophhu/ngx-datatable';
@NgModule({
imports: [
DatatableComponent,
...
]
...
})Add the table options and data source in your component.ts file.
easydata$: Observable<any[]> = of([
{ date: '01.01.2024 00:00:59', description: 'Berlin', klar: true },
{ date: '01.01.2023 00:00:59', description: 'Hamburg', klar: false },
])
easytable: Tableoptions = {
columns: [
{ id: '1', name: 'date', header: 'Datum/Zeit', cell: 'date', pipe: { name: DatePipe, args: 'dd.MM.yyyy HH:mm:ss'}, hidden: false, sortable: true },
{ id: '2', name: 'description', header: 'Beschreibung', cell: 'description', hidden: false, sortable: true },
{ id: '3', name: 'klar', header: 'Klar', cell: 'klar', type: 'checkbox', disabled: true, hidden: false, sortable: true }
]
}Then, you can use the <ngx-datatable> component in your HTML templates as shown below:
<ngx-datatable [tableoptions]="easytable" [data$]="easydata$"></ngx-datatable>License
This project is licensed under the MIT License.
The MIT License (MIT) Copyright © 2025
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the “Software”), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
