Closed
Description
Describe the bug
netlify-plugin-nextjs seems to overwrite custom _redirects
file rules
To Reproduce
Steps to reproduce the behavior:
- Add custom rules to:
public/_redirects
- netlify build
- Check
out_publish/_redirects
includes only# Next-on-Netlify Redirects
....
Expected behavior
I would expect to see the custom redirect rules merged in at the very top of the out_publish/_redirects
file
Versions
- Next.js:
"next": "^10.0.3"
- plugin (if installed at fixed version):
"@netlify/plugin-nextjs": "^3.0.0"
If you're using the CLI to build
- OS: [e.g. macOS, Windows]:
Mac
- netlify/cli version:
netlify-cli@3.10.5
If you're using file-based installation
- netlify.toml:
# netlify.toml
[build]
# base = "storefront/"
command = "yarn build"
publish = "storefront/out_publish"
functions = "storefront/out_functions"
[dev]
functions = "out_functions"
publish = "out_publish"
framework = "#static"
# needs to be included before
[[plugins]]
package = "/plugins/my-custom-plugin"
[plugins.inputs]
build_dir_path = "storefront"
build_dir = ".next"
json_dir = "public/json"
[[plugins]]
package = "@netlify/plugin-nextjs"
Custom _redirects
#### PRODUCTS REDIRECTS START ####
/json/products/navy-feel-good-short-sleeve-shirt /json/products/navy-feel-good-short-sleeve-shirt___2021-03-16T22:24:05Z.json 200
.......
#### PRODUCTS REDIRECTS END ####
Metadata
Metadata
Assignees
Labels
No labels