From f946780bab8901acb61b9df38ab5628448a0c622 Mon Sep 17 00:00:00 2001 From: Vladimir Mandic Date: Mon, 25 Jul 2022 08:20:59 -0400 Subject: [PATCH] refactor dependencies --- .npmrc | 5 ++++- README.md | 4 +++- package.json | 57 ++++++++++++++++++++++++++-------------------------- 3 files changed, 35 insertions(+), 31 deletions(-) diff --git a/.npmrc b/.npmrc index 53a8862..29879f1 100644 --- a/.npmrc +++ b/.npmrc @@ -1 +1,4 @@ -force = true +force=true +production=true +legacy-peer-deps=true +strict-peer-dependencies=false diff --git a/README.md b/README.md index 4ab1a20..78bfa25 100644 --- a/README.md +++ b/README.md @@ -314,6 +314,8 @@ Pretrained models and their weights are includes in `./model`. ## Test & Dev Web Server +To install development dependencies, use `npm install --production=false` + Built-in test&dev web server can be started using ```shell @@ -389,7 +391,7 @@ cd face-api Then install all dependencies and run rebuild: ```shell -npm install +npm install --production=false npm run build ``` diff --git a/package.json b/package.json index 0ac0b21..5be9cc5 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@vladmandic/face-api", - "version": "1.6.11", + "version": "1.7.0", "description": "FaceAPI: AI-powered Face Detection & Rotation Tracking, Face Description & Recognition, Age & Gender & Emotion Prediction for Browser and NodeJS using TensorFlow/JS", "sideEffects": false, "main": "dist/face-api.node.js", @@ -41,43 +41,42 @@ "tensorflowjs", "tfjs" ], - "devDependencies": { + "optionalDependencies": { "@canvas/image": "^1.0.1", - "@microsoft/api-extractor": "^7.24.1", - "@tensorflow/tfjs": "^3.18.0", - "@tensorflow/tfjs-backend-cpu": "^3.18.0", - "@tensorflow/tfjs-backend-wasm": "^3.18.0", - "@tensorflow/tfjs-backend-webgl": "^3.18.0", - "@tensorflow/tfjs-backend-webgpu": "0.0.1-alpha.11", - "@tensorflow/tfjs-converter": "^3.18.0", - "@tensorflow/tfjs-core": "^3.18.0", - "@tensorflow/tfjs-data": "^3.18.0", - "@tensorflow/tfjs-layers": "^3.18.0", - "@tensorflow/tfjs-node": "^3.18.0", - "@tensorflow/tfjs-node-gpu": "^3.18.0", - "@types/node": "^17.0.35", - "@types/offscreencanvas": "^2019.6.4", - "@typescript-eslint/eslint-plugin": "^5.26.0", - "@typescript-eslint/parser": "^5.26.0", - "@vladmandic/build": "^0.7.4", - "@vladmandic/pilogger": "^0.4.4", + "canvas": "^2.9.3", + "node-fetch": "^3.2.9" + }, + "devDependencies": { + "@microsoft/api-extractor": "^7.28.6", + "@tensorflow/tfjs": "^3.19.0", + "@tensorflow/tfjs-backend-cpu": "^3.19.0", + "@tensorflow/tfjs-backend-wasm": "^3.19.0", + "@tensorflow/tfjs-backend-webgl": "^3.19.0", + "@tensorflow/tfjs-backend-webgpu": "0.0.1-alpha.12", + "@tensorflow/tfjs-converter": "^3.19.0", + "@tensorflow/tfjs-core": "^3.19.0", + "@tensorflow/tfjs-data": "^3.19.0", + "@tensorflow/tfjs-layers": "^3.19.0", + "@tensorflow/tfjs-node": "^3.19.0", + "@tensorflow/tfjs-node-gpu": "^3.19.0", + "@types/node": "^18.6.1", + "@types/offscreencanvas": "^2019.7.0", + "@typescript-eslint/eslint-plugin": "^5.30.7", + "@typescript-eslint/parser": "^5.30.7", + "@vladmandic/build": "^0.7.7", + "@vladmandic/pilogger": "^0.4.5", "@vladmandic/tfjs": "github:vladmandic/tfjs", - "canvas": "^2.9.1", - "chokidar": "^3.5.3", - "dayjs": "^1.11.2", - "esbuild": "^0.14.39", - "eslint": "^8.16.0", + "esbuild": "^0.14.50", + "eslint": "^8.20.0", "eslint-config-airbnb-base": "^15.0.0", "eslint-plugin-import": "^2.26.0", "eslint-plugin-json": "^3.1.0", "eslint-plugin-node": "^11.1.0", "eslint-plugin-promise": "^6.0.0", - "node-fetch": "^3.2.4", "rimraf": "^3.0.2", "seedrandom": "^3.0.5", - "simple-git": "^3.7.1", "tslib": "^2.4.0", - "typedoc": "^0.22.15", - "typescript": "4.6.4" + "typedoc": "^0.23.9", + "typescript": "4.7.4" } }