Skip to content

Instantly share code, notes, and snippets.

@jerriclynsjohn
Created September 8, 2021 15:20
Show Gist options
  • Save jerriclynsjohn/41b5efc1aedfee0b76602743b0b30b64 to your computer and use it in GitHub Desktop.
Save jerriclynsjohn/41b5efc1aedfee0b76602743b0b30b64 to your computer and use it in GitHub Desktop.
# example netlify.toml
[build]
command = "npm run build"
functions = "functions"
publish = "public"
## Uncomment to use this redirect for Single Page Applications like create-react-app.
## Not needed for static site generators.
[[redirects]]
from = "/*"
to = "/index.html"
status = 200
## (optional) Settings for Netlify Dev
## https://github.com/netlify/cli/blob/master/docs/netlify-dev.md#project-detection
[dev]
command = "yarn start" # Command to start your dev server
port = 3000 # Port that the dev server will be listening on
publish = "dist" # Folder with the static content for _redirect file
## more info on configuring this file: https://www.netlify.com/docs/netlify-toml-reference/
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment