Logo
BEAUTY IN SIMPLE

Digital Garden

A collection of short solutions to daily tech problems, notes, some thoughts and explorations that might convert into a blog post someday. My take on Learn in public concept.

title: "Netlify"

Netlify

  1. Prevent Netlify from treating warnings as errors during the build
  2. React - page not found when using React router

Prevent Netlify from treating warnings as errors during the build

  • Site settings -> Build & Deploy -> Continuous deployment -> Edit settings

  • Enter Build command

CI='' <your_build_command>

Build command options:

  • npm run build
  • yarn build
  • gatsby build

and so on.

Docs

React - page not found when using React router

  • In the public folder of a project create file _redirects

  • Add the following rewrite rule

/* /index.html 200
  • Redeploy your site

Docs