2
0
mirror of https://github.com/inventree/InvenTree.git synced 2025-06-17 04:25:42 +00:00

Add netlify for fast previews (#5353)

* Add netlify to readme

* add redirect for testing

* fix command

* add SPA redirect

* run desktop lighthouse tests

* add base dir

* remove base dir - use app redirect

* remove unneeded redirect

* remove status

* remove status

* static redirects

* remove toml redirect

* use toml again

* make redirect conditional

* add debug msg

* remove check section
This commit is contained in:
Matthias Mair
2023-07-27 03:17:44 +02:00
committed by GitHub
parent 339eae53a1
commit 39464f645a
3 changed files with 27 additions and 0 deletions

19
src/frontend/netlify.toml Normal file
View File

@ -0,0 +1,19 @@
# Netlify configuration file
# https://www.netlify.com/docs/netlify-toml-reference/
[build]
command = "yarn run build --outDir dist"
publish = "dist"
# Send requests to subpath
[[redirects]]
from = "/*"
to = "/index.html"
status = 200
[[plugins]]
package = "@netlify/plugin-lighthouse"
[plugins.inputs.settings]
preset = "desktop" # Optionally run Lighthouse using a desktop configuration