So you made a Single Page Application and It’s working great on localhost npm or yarn server. And now you made a build of this site and deploy it t...
For further actions, you may consider blocking this person and/or reporting abuse
Thanks for this, Rajesh! You definitely put me on the right track. I found the _redirects file didn't seem to like working with my netlify.toml, which I was already using to redirect API calls to my backend. I found this sample code to add to my netlify.toml file in the Netlify documentation:
[COMMENT] The following redirect is intended for use with most SPAs that handle routing internally.
[[redirects]]
from = "/*"
to = "/index.html"
status = 200
Link to documentation here: docs.netlify.com/configure-builds/...
Tip: scroll through the sample file that is provided or use find on your browser as it is kind of lost in a sea of other sample code.
Thanks @mellim
This detailed comment is definitely going to help somebody.
this did work for me when i deployed it on Netlify platform, but failed to work when deployed the same static site on Render platform. Can you explain, how to solve the issue while deploying on render platform
I never worked with this platform before.
This was my solution. Thanks a lot, Mel!
I tried this and still did not work
Maybe you missed any config or having some other issue with project. please provide more information so people from comments can also help. Thanks.
For me too.
Thanks thats saved me haha
you're welcome 😀
Thank you so much for this fix. This is a really useful tip.
very helpful
Thanks! Worked awesome.
I had missed the note to add
_redirects
topublic/
folder. Fixed and good!This is very helpful, thank you!
Hey, Rajesh! You helped me a lot! Thank you very much!
this worked for me! thank you :-)
You are a life saver!!! Thanks from the bottom of my heart <3
Your welcome sir 😉
You saved me!! Thank you so much!!!
You are doing god's work
heheheh 😄
thanks a lot man
Thanks 🙏
Thank you! That was what I needed.
Thank you. Simple & effective
life saver!, thanks for this, i spent days researching this issue and was about to give up
Arigato !!
love u
Thanks a lot, man!
You are a live saver my man
Wow! Thanks a lot man!
Thanks man :)
you're welcome 😀
I had the same issue and it worked for me. Thank you man!
It works. Thanks!
hi, why it doesnt work on custom domain?
You saved my life Brother ! Lots of love <3
Thanks for this post. It actually helped a lot !
Thanks a lot. Solved my problem.
Helpful!
Saved my life
Thanks, for sharing
thank you for save my project. haha :)
Thanks for this concise solution. It saved me quite a lot of time!
I have been looking everywhere for a solution thank you!
You sir are a life saver! Thank you!!!
Thank you. This solved my problem.
This is really helpful! Permission to share on my dev page
Thanks man!
It worked! Thanks, really good explanation.
thanks
thanks Rajesh, perfect answer
Thank you very much Rajesh ⭐
That worked!, Thanks a lot man
It's working! Thanks Rajesh.
Thanks man 🙏🙏🙏
You are the best!
Thanks man <3
You are awesome, thanks!!!
I have on question though, will I have the same problem if I deploy my app to another hosting provider?
Or is it a strictly netlify issue??
depends on the configuration of that host, please read their documentation related to routing.
Thanks @mellim 👍
hey there still not working
Thanks bro!! It worked
Thanks man! It's works for me!
Hello, I'm newbie of Netlify and use React JS for almost default frontend framework. This solution article is helpful. Thanks
Saved me! thank you!
Thanks. It worked for me.
Thanks for sharing. This worked fine.
Awesome!
Sorted my issue and just started writing a well explained PR, by resolving this issue
Thank you Rajesh 🤝
Thank you soo much ! it work perfectly
Thank you very much
THANK YOU SO MUCH