Skip to content

Commit

Permalink
build with: ng packagr
Browse files Browse the repository at this point in the history
  • Loading branch information
jrgokavalsa committed Feb 1, 2024
1 parent 72635a0 commit 91117bc
Show file tree
Hide file tree
Showing 9 changed files with 660 additions and 185 deletions.
6 changes: 3 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
},
"namespace": "@tanstack",
"devDependencies": {
"@angular-devkit/core": "~17.1.0",
"@angular/core": "^17.1.2",
"@babel/core": "^7.23.7",
"@babel/preset-env": "^7.23.8",
"@babel/preset-react": "^7.23.3",
Expand All @@ -50,6 +50,7 @@
"@types/react-dom": "^18.2.18",
"babel-plugin-transform-async-to-promises": "^0.8.18",
"jsdom": "^23.2.0",
"ng-packagr": "^17.1.2",
"nx": "^17.2.8",
"prettier": "^4.0.0-alpha.8",
"prettier-plugin-svelte": "^3.1.2",
Expand All @@ -66,6 +67,5 @@
"vite": "^5.0.11",
"vitest": "^1.2.0",
"vue": "^3.4.14"
},
"dependencies": {}
}
}
8 changes: 8 additions & 0 deletions packages/angular-table/ng-package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
{
"$schema": "../../node_modules/ng-packagr/ng-package.schema.json",
"dest": "./build/",
"lib": {
"entryFile": "src/public-api.ts"
},
"allowedNonPeerDependencies": ["@tanstack/table-core"]
}
24 changes: 11 additions & 13 deletions packages/angular-table/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,17 +20,14 @@
"angular-table",
"datagrid"
],
"type": "commonjs",
"module": "build/lib/index.esm.js",
"main": "build/lib/index.js",
"types": "build/lib/index.d.ts",
"type": "module",
"module": "fesm2022/tanstack-angular-table.mjs",
"main": "index.d.ts",
"types": "index.d.ts",
"exports": {
".": {
"types": "./build/lib/index.d.ts",
"import": "./build/lib/index.mjs",
"default": "./build/lib/index.js"
},
"./package.json": "./package.json"
"./package.json": {
"default": "./package.json"
}
},
"engines": {
"node": ">=12"
Expand All @@ -43,16 +40,17 @@
"scripts": {
"clean": "rimraf ./build",
"test:types": "tsc --noEmit",
"build": "pnpm build:rollup && pnpm build:types",
"build": "pnpm ng-packagr -p ng-package.json",
"build:rollup": "rollup --config rollup.config.mjs",
"build:types": "tsc --emitDeclarationOnly"
},
"dependencies": {
"tslib": "^2.3.0",
"@tanstack/table-core": "workspace:*"
},
"peerDependencies": {
"@angular/common": "^17.0.0",
"@angular/core": "^17.0.0"
"@angular/core": "^17.1.2",
"@angular/common": "^17.1.2"
},
"sideEffects": false
}
15 changes: 0 additions & 15 deletions packages/angular-table/rollup.config.mjs

This file was deleted.

59 changes: 0 additions & 59 deletions packages/angular-table/src/flexrender.directive.ts

This file was deleted.

41 changes: 0 additions & 41 deletions packages/angular-table/src/index.ts

This file was deleted.

7 changes: 7 additions & 0 deletions packages/angular-table/src/public-api.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
/*
* Public API Surface of angular-table
*/

export * from '@tanstack/table-core'
export * from './lib/flexrender.directive'
export * from './lib/index'
11 changes: 7 additions & 4 deletions packages/angular-table/tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,10 +1,13 @@
{
"extends": "../../tsconfig.json",
"compilerOptions": {
"rootDir": "./src",
"outDir": "./build/lib",
"experimentalDecorators": true,
"emitDecoratorMetadata": true
"declarationMap": false,
"types": []
},
"include": ["src"]
"angularCompilerOptions": {
"compilationMode": "partial"
},
"include": ["src", "public-api.ts"],
"exclude": ["**/*.spec.ts"]
}
Loading

0 comments on commit 91117bc

Please sign in to comment.