Skip to content

netlify

Tom Wilson edited this page Jun 12, 2019 · 1 revision

ipress2

Deploying static sites should be simple one command, one pull request, etc. Netlify is the answer to static site deploys.

npm install netlify-cli -g
netlify login
netlify deploy --dir=dist # deploy to staging verify site
netlify deploy --dir=dist --prod

So that is the getting started part, once you have that part completed, then rinse and repeat:

netlify deploy --dir=dist
netlify deploy --dir=dist --prod

If you want to be fancy add some build scripts:

package.json

{
  "scripts": {
     "deploy:staging": "netlify deploy --dir=dist",
     "deploy:prod": "netify deploy --dir=dist --prod"
  }
}
Clone this wiki locally