From 6455ac865d1c3850f7966afaa31116337bfac7f7 Mon Sep 17 00:00:00 2001 From: rozetko Date: Thu, 15 Jun 2023 16:49:07 +0300 Subject: [PATCH] rename dist/ to lib/ && do not push anything except lib/ to npm --- .gitignore | 2 ++ build/webpack.base.conf.js | 2 +- package.json | 7 +++++-- tsconfig.json | 2 +- 4 files changed, 9 insertions(+), 4 deletions(-) diff --git a/.gitignore b/.gitignore index 03c1a21..5c973ee 100755 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,5 @@ node_modules .vscode + dist +lib diff --git a/build/webpack.base.conf.js b/build/webpack.base.conf.js index a3fe50d..4dbff32 100755 --- a/build/webpack.base.conf.js +++ b/build/webpack.base.conf.js @@ -31,7 +31,7 @@ module.exports = { }, output: { filename: 'index.js', - path: resolve('dist'), + path: resolve('lib'), libraryTarget: 'umd', umdNamedDefine: true } diff --git a/package.json b/package.json index ba1b4a1..ff58f7a 100755 --- a/package.json +++ b/package.json @@ -2,8 +2,11 @@ "name": "@chartwerk/core", "version": "0.6.13", "description": "Chartwerk core", - "main": "dist/index.js", - "types": "dist/index.d.ts", + "main": "lib/index.js", + "types": "lib/index.d.ts", + "files": [ + "/lib" + ], "scripts": { "build": "webpack --config build/webpack.prod.conf.js", "dev": "webpack --config build/webpack.dev.conf.js", diff --git a/tsconfig.json b/tsconfig.json index 558c8fc..2a79ccc 100755 --- a/tsconfig.json +++ b/tsconfig.json @@ -4,7 +4,7 @@ "rootDir": "./src", "module": "esnext", "declaration": true, - "declarationDir": "dist", + "declarationDir": "lib", "allowSyntheticDefaultImports": true, "inlineSourceMap": false, "sourceMap": true,