add cross-env package and script for running both ports

This commit is contained in:
aminamos
2020-04-07 08:55:11 -07:00
parent b0017ce6aa
commit 41e6eeec32

View File

@@ -4,7 +4,8 @@
"description": "Source code for the Pluralsight course JavaScript Promises and Async Programming", "description": "Source code for the Pluralsight course JavaScript Promises and Async Programming",
"main": "index.js", "main": "index.js",
"scripts": { "scripts": {
"dev": "nodemon ./index.js" "dev": "nodemon ./index.js",
"secondary": "cross-env PORT=3001 nodemon ./index.js"
}, },
"repository": { "repository": {
"type": "git", "type": "git",
@@ -17,6 +18,7 @@
}, },
"homepage": "https://github.com/taylonr/async-programming-promises#readme", "homepage": "https://github.com/taylonr/async-programming-promises#readme",
"dependencies": { "dependencies": {
"cross-env": "^7.0.2",
"express": "^4.17.1", "express": "^4.17.1",
"json-server": "^0.15.1" "json-server": "^0.15.1"
}, },