From 60a4153ecdc2fb1782593becae2ba62affd5e57a Mon Sep 17 00:00:00 2001 From: nerdeveloper Date: Fri, 4 Sep 2020 15:58:48 +0100 Subject: [PATCH 1/2] fix(package): added support for windows users when start the app fix #5 --- package-lock.json | 52 +++++++++++++++++++++++++++++++++++++++++++++++ package.json | 9 ++++---- 2 files changed, 57 insertions(+), 4 deletions(-) diff --git a/package-lock.json b/package-lock.json index 3beedd6..b5c5183 100644 --- a/package-lock.json +++ b/package-lock.json @@ -5160,6 +5160,58 @@ "moment-timezone": "^0.5.x" } }, + "cross-env": { + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/cross-env/-/cross-env-7.0.2.tgz", + "integrity": "sha512-KZP/bMEOJEDCkDQAyRhu3RL2ZO/SUVrxQVI0G3YEQ+OLbRA3c6zgixe8Mq8a/z7+HKlNEjo8oiLUs8iRijY2Rw==", + "dev": true, + "requires": { + "cross-spawn": "^7.0.1" + }, + "dependencies": { + "cross-spawn": { + "version": "7.0.3", + "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-7.0.3.tgz", + "integrity": "sha512-iRDPJKUPVEND7dHPO8rkbOnPpyDygcDFtWjpeWNCgy8WP2rXcxXL8TskReQl6OrB2G7+UJrags1q15Fudc7G6w==", + "dev": true, + "requires": { + "path-key": "^3.1.0", + "shebang-command": "^2.0.0", + "which": "^2.0.1" + } + }, + "path-key": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/path-key/-/path-key-3.1.1.tgz", + "integrity": "sha512-ojmeN0qd+y0jszEtoY48r0Peq5dwMEkIlCOu6Q5f41lfkswXuKtYrhgoTpLnyIcHm24Uhqx+5Tqm2InSwLhE6Q==", + "dev": true + }, + "shebang-command": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/shebang-command/-/shebang-command-2.0.0.tgz", + "integrity": "sha512-kHxr2zZpYtdmrN1qDjrrX/Z1rR1kG8Dx+gkpK1G4eXmvXswmcE1hTWBWYUzlraYw1/yZp6YuDY77YtvbN0dmDA==", + "dev": true, + "requires": { + "shebang-regex": "^3.0.0" + } + }, + "shebang-regex": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/shebang-regex/-/shebang-regex-3.0.0.tgz", + "integrity": "sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A==", + "dev": true + }, + "which": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/which/-/which-2.0.2.tgz", + "integrity": "sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA==", + "dev": true, + "requires": { + "isexe": "^2.0.0" + } + } + } + }, "cross-spawn": { "version": "6.0.5", "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-6.0.5.tgz", diff --git a/package.json b/package.json index 0118da6..d61263b 100644 --- a/package.json +++ b/package.json @@ -6,10 +6,10 @@ "scripts": { "start": "npm run build:dev", "lint": "./node_modules/.bin/eslint '**/*.ts' --fix --quiet", - "test": "NODE_ENV=development jest --runInBand --forceExit", - "serve:dev": "NODE_ENV=development nodemon dist/server.js --public ", - "docker:serve": "NODE_ENV=development nodemon dist/server.js --public", - "serve:prod": " NODE_ENV=production ./node_modules/.bin/nodemon app/dist/server.js --public", + "test": "cross-env NODE_ENV=development jest --runInBand --forceExit", + "serve:dev": "cross-env NODE_ENV=development nodemon dist/server.js --public ", + "docker:serve": "cross-env NODE_ENV=development nodemon dist/server.js --public", + "serve:prod": "cross-env NODE_ENV=production ./node_modules/.bin/nodemon app/dist/server.js --public", "watch-node": "./node_modules/.bin/nodemon dist/server.js", "watch": "concurrently \"npm run bundle:watch \" \"npm run watch-ts:dev \" \"npm run serve:dev \" --names \"💻,📦\" --prefix name", "watch:serve": " concurrently \"npm run bundle:watch \" \"npm run serve:prod \" \"npm run watch-ts:prod \" --names \"💻,📦\" --prefix name", @@ -114,6 +114,7 @@ "babel-plugin-transform-util-promisify": "^0.2.2", "babel-preset-env": "^1.7.0", "concurrently": "^4.1.2", + "cross-env": "^7.0.2", "css-loader": "^3.2.0", "cz-conventional-changelog": "^3.0.2", "eslint": "^5.16.0", From d885ef09717e29f7c469bcd18791c5943662b0d4 Mon Sep 17 00:00:00 2001 From: nerdeveloper Date: Fri, 4 Sep 2020 16:05:40 +0100 Subject: [PATCH 2/2] refactor(package): remove body parser as it is not used in the codebase --- package.json | 2 -- 1 file changed, 2 deletions(-) diff --git a/package.json b/package.json index d61263b..eafa099 100644 --- a/package.json +++ b/package.json @@ -33,7 +33,6 @@ "author": "Obinna Odirionye", "license": "MIT", "dependencies": { - "body-parser": "^1.19.0", "compression": "^1.7.4", "connect-ensure-login": "^0.1.1", "connect-flash": "^0.1.1", @@ -73,7 +72,6 @@ "@babel/core": "^7.3.4", "@babel/preset-env": "^7.3.4", "@release-it/conventional-changelog": "^1.1.0", - "@types/body-parser": "^1.17.0", "@types/compression": "^0.0.36", "@types/connect-ensure-login": "^0.1.5", "@types/connect-flash": "0.0.35",