Skip to content

Instantly share code, notes, and snippets.

@Siilwyn
Last active March 6, 2023 12:41
Show Gist options
  • Save Siilwyn/4cca411fc0d33244fae758bdd6dfc347 to your computer and use it in GitHub Desktop.
Save Siilwyn/4cca411fc0d33244fae758bdd6dfc347 to your computer and use it in GitHub Desktop.
Netlify TOML configuration for static websites
[build]
command = "npm run build"
publish = "dist"
[build.environment]
NODE_ENV = "production"
NPM_CONFIG_AUDIT = "false"
NPM_CONFIG_FUND = "false"
NPM_FLAGS = "--ignore-scripts"
[build.processing.html]
pretty_urls = true
[[headers]]
for = "/*"
[headers.values]
Strict-Transport-Security = "max-age=63072000; includeSubDomains; preload"
Referrer-Policy = "no-referrer-when-downgrade"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment