Skip to content
This repository was archived by the owner on Dec 25, 2021. It is now read-only.

Commit 124958c

Browse files
authored
Merge pull request #24 from brunano21/fix/pub_scripts
Rename package. Fix publish scripts.
2 parents ed463ac + a2bbdec commit 124958c

14 files changed

Lines changed: 29 additions & 25 deletions

README.md

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22

33
*Note*: Originally this was fork of this [package](https://github.com/MIt9/angular-4-data-table).
44

5+
*Important*: Since v1.0.0 the package was renamed from `angular5-data-table` to `angular5-datatable`.
6+
57
A simple Angular 5 data table, with built-in solutions for features including:
68
* pagination
79
* sorting
@@ -13,7 +15,7 @@ A simple Angular 5 data table, with built-in solutions for features including:
1315

1416
The component can be used not just with local data, but remote resources too, ie. when sorting and/or pagination are implemented server side.
1517

16-
The library is packaged with [`ng-packgr`](https://github.com/dherges/ng-packagr).
18+
The library is packaged with [`ng-packagr`](https://github.com/dherges/ng-packagr).
1719

1820
## Dependencies
1921
Furthermore the component is based on Bootstrap v4.0 (*CSS-only*) and Font-Awesome v4.7, hence be sure to include them into your project.
@@ -42,7 +44,7 @@ npm install bootstrap@4.0.0 font-awesome@4.7.0
4244
## Installation
4345

4446
```bash
45-
npm install @angular5/datatable
47+
npm install angular5-datatable
4648
```
4749

4850
## Usage
@@ -51,7 +53,7 @@ npm install @angular5/datatable
5153
```ts
5254
import { BrowserModule } from '@angular/platform-browser';
5355
import { NgModule } from '@angular/core';
54-
import { DataTableModule } from '@angular5/datatable';
56+
import { DataTableModule } from 'angular5-datatable';
5557

5658
@NgModule({
5759
imports: [

libs/datatable/README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,15 +35,15 @@ npm install bootstrap@4.0.0 font-awesome@4.7.0
3535
---
3636
# Installation
3737
```bash
38-
npm install @angular5/datatable
38+
npm install angular5-datatable
3939
```
4040
---
4141
# Usage
4242
#### 1.Import Datatable module
4343
```ts
4444
import { BrowserModule } from '@angular/platform-browser';
4545
import { NgModule } from '@angular/core';
46-
import { DataTableModule } from '@angular5/datatable';
46+
import { DataTableModule } from 'angular5-datatable';
4747

4848
@NgModule({
4949
imports: [

libs/datatable/package.json

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,8 @@
11
{
2-
"name": "@angular5/datatable",
3-
"description": "This library contains a Datatable component.",
2+
"name": "angular5-datatable",
3+
"description": "This library contains an Angualar5-compatible Datatable component.",
44
"version": "1.0.0",
5+
"private": false,
56
"license": "MIT",
67
"repository": "https://github.com/brunano21/angular-4-data-table",
78
"peerDependencies": {
@@ -10,7 +11,7 @@
1011
},
1112
"ngPackage": {
1213
"$schema": "./node_modules/ng-packagr/ng-package.schema.json",
13-
"dest": "../../dist/angular5/datatable",
14+
"dest": "../../dist/angular5-datatable",
1415
"workingDirectory": "./.ng_build",
1516
"lib": {
1617
"entryFile": "src/public_api.ts"

package.json

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
{
2-
"name": "angular5-datatable-demo",
2+
"name": "angular5-datable-demo",
33
"version": "0.1.0",
44
"license": "MIT",
5-
"private": true,
5+
"private": false,
66
"scripts": {
77
"ng": "ng",
88
"start": "ng serve",
@@ -11,9 +11,10 @@
1111
"lint": "ng lint",
1212
"e2e": "ng e2e",
1313
"build:docs": "compodoc ./libs -p src/tsconfig.packages.json -s",
14-
"build:app": "cpr dist/angular5-datatable src/@angualar5-datatable --overwrite && ng build --app packages && rimraf src/@angular5-datatable",
15-
"build:app:prod": "cpr dist/angular5-datatable src/@angular5-datatable --overwrite && ng build --prod --named-chunks=true --app packages && rimraf src/@angular5-datatable",
16-
"build:libs:datatable": "ng-packagr -p libs/datatable/package.json"
14+
"build:app": "cpr dist/angular5-datatable src/angualar5-datatable --overwrite && ng build --app packages && rimraf src/angular5-datatable",
15+
"build:app:prod": "cpr dist/angular5-datatable src/angular5-datatable --overwrite && ng build --prod --named-chunks=true --app packages && rimraf src/angular5-datatable",
16+
"build:libs:datatable": "ng-packagr -p libs/datatable/package.json",
17+
"publish:libs:datatable": "npm publish dist/angular5-datatable"
1718
},
1819
"dependencies": {
1920
"@angular/animations": "^5.2.0",

src/app/components/datatable/datatable.module.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ import { CommonModule } from '@angular/common';
33
import { BrowserModule } from '@angular/platform-browser';
44
import { FormsModule } from '@angular/forms';
55
// module
6-
import { DataTableModule } from '@angular5/datatable';
6+
import { DataTableModule } from 'angular5-datatable';
77
// demo components
88
import { DataTableDemo1Component } from './demo1/data-table-demo1';
99
import { DataTableDemo2Component } from './demo2/data-table-demo2';

src/app/components/datatable/demo1/data-table-demo1.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import { Component } from '@angular/core';
22
import persons from './data-table-demo1-data';
3-
import { DataTableResource } from '@angular5/datatable';
3+
import { DataTableResource } from 'angular5-datatable';
44

55
@Component({
66
selector: 'app-data-table-demo-1',

src/app/components/datatable/demo2/data-table-demo2.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import { Component, ViewChild } from '@angular/core';
22
import { Cars } from './data-table-demo2-data';
3-
import { DataTable, DataTableResource } from '@angular5/datatable';
3+
import { DataTable, DataTableResource } from 'angular5-datatable';
44

55

66
@Component({

src/app/components/datatable/demo3/data-table-demo3.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import { Component, ViewChild } from '@angular/core';
22
import { films } from './data-table-demo3-data';
3-
import { DataTable, DataTableResource, DataTableTranslations } from '@angular5/datatable';
3+
import { DataTable, DataTableResource, DataTableTranslations } from 'angular5-datatable';
44

55

66
@Component({

src/app/components/datatable/demo4/data-table-resources-custom.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { DataTableResource, DataTableParams } from '@angular5/datatable';
1+
import { DataTableResource, DataTableParams } from 'angular5-datatable';
22

33
export class DataTableResourceCustom<T> extends DataTableResource<T> {
44

src/app/components/datatable/demo5/data-table-demo5.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import { Component, ViewChild } from '@angular/core';
2-
import { DataTable, DataTableResource } from '@angular5/datatable';
2+
import { DataTable, DataTableResource } from 'angular5-datatable';
33

44

55
@Component({

0 commit comments

Comments
 (0)