From 62b59b1e6ddbfc3e324b082f5080e2b3dbc549fe Mon Sep 17 00:00:00 2001 From: mvllow Date: Sun, 24 Nov 2019 16:07:43 -0600 Subject: [PATCH 1/2] add sirv-cli to dev deps --- package.json | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/package.json b/package.json index 4e791f57..45474784 100644 --- a/package.json +++ b/package.json @@ -8,11 +8,9 @@ "rollup-plugin-node-resolve": "^5.2.0", "rollup-plugin-svelte": "^5.0.3", "rollup-plugin-terser": "^5.1.2", + "sirv-cli": "^0.4.4", "svelte": "^3.0.0" }, - "dependencies": { - "sirv-cli": "^0.4.4" - }, "scripts": { "build": "rollup -c", "dev": "rollup -c -w", From ed142de3c8a913900808cfa64fc1e8012346d394 Mon Sep 17 00:00:00 2001 From: mvllow Date: Sun, 24 Nov 2019 16:08:18 -0600 Subject: [PATCH 2/2] docs: use sirv-cli in production --- README.md | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index c740b88f..a80e11e9 100644 --- a/README.md +++ b/README.md @@ -44,7 +44,11 @@ To create an optimised version of the app: npm run build ``` -You can run the newly built app with `npm run start`. This uses [sirv](https://github.com/lukeed/sirv), which is included in your package.json's `dependencies` so that the app will work when you deploy to platforms like [Heroku](https://heroku.com). +You can run the newly built app with `npm run start`. This uses [sirv](https://github.com/lukeed/sirv), which is included in your package.json's `devDependencies`. When deploying to platforms like [Heroku](https://heroku.com), ensure `sirv-cli` is a production dependency. + +```js +npm install --save-prod sirv-cli +``` ## Single-page app mode