From 0d702eba9525849b9a59139c71f25b7a237d5416 Mon Sep 17 00:00:00 2001 From: Erik Golinelli Date: Mon, 11 Dec 2023 20:23:05 +0100 Subject: [PATCH] Add @vercel/ncc package and create 'package' script The @vercel/ncc package was added to the dependencies in package.json and package-lock.json. This package will be used to compile Node.js applications into a single file. Along with the addition of this package, a 'package' script has been added to the scripts section of package.json to facilitate the bundling of the application. Took 10 minutes --- package-lock.json | 10 ++++++++++ package.json | 2 ++ 2 files changed, 12 insertions(+) diff --git a/package-lock.json b/package-lock.json index 7abc461..044e9e9 100644 --- a/package-lock.json +++ b/package-lock.json @@ -19,6 +19,7 @@ "@types/node": "^18.19.3", "@typescript-eslint/eslint-plugin": "^6.14.0", "@typescript-eslint/parser": "^6.14.0", + "@vercel/ncc": "^0.38.1", "eslint": "^8.55.0", "typescript": "^5.3.3" } @@ -456,6 +457,15 @@ "integrity": "sha512-zuVdFrMJiuCDQUMCzQaD6KL28MjnqqN8XnAqiEq9PNm/hCPTSGfrXCOfwj1ow4LFb/tNymJPwsNbVePc1xFqrQ==", "dev": true }, + "node_modules/@vercel/ncc": { + "version": "0.38.1", + "resolved": "https://registry.npmjs.org/@vercel/ncc/-/ncc-0.38.1.tgz", + "integrity": "sha512-IBBb+iI2NLu4VQn3Vwldyi2QwaXt5+hTyh58ggAMoCGE6DJmPvwL3KPBWcJl1m9LYPChBLE980Jw+CS4Wokqxw==", + "dev": true, + "bin": { + "ncc": "dist/ncc/cli.js" + } + }, "node_modules/acorn": { "version": "8.11.2", "resolved": "https://registry.npmjs.org/acorn/-/acorn-8.11.2.tgz", diff --git a/package.json b/package.json index 85e636a..9fc521c 100644 --- a/package.json +++ b/package.json @@ -15,6 +15,7 @@ "main": "lib/main.js", "scripts": { "build": "tsc", + "package": "ncc build src/index.ts --source-map --license licenses.txt", "lint": "eslint src --fix", "tsdoc": "npx typedoc src/*" }, @@ -42,6 +43,7 @@ "@types/node": "^18.19.3", "@typescript-eslint/eslint-plugin": "^6.14.0", "@typescript-eslint/parser": "^6.14.0", + "@vercel/ncc": "^0.38.1", "eslint": "^8.55.0", "typescript": "^5.3.3" }