vuejs 404 error on shared hosting but on aws works fine - vue.js

I have vuejs app which is working fine on aws but if I deploy on shared hosting then website works fine but if refresh on a page then it throws 404 error.
I used: createWebHistory in router index file
I also used createWebHashHistory too but refresh page will not work. It throws the below error
The document you are looking for may have been removed or re-named. Please contact the web site owner for further assistance.
If I go to home page and switch menus then it works properly.
Please advise
Thanks

Related

Getting a blank page after deploying static web app service in azure from already deployed Github pages

Github pages are perfectly running and i got no errors on workflow actions on deploying on azure,
but iam getting blank page on url provided by azure.
Please help to deploy my site on azure (static web app service) with already deployed github pages
it would be great help....
Update the basehref in index.html or you can delete that line from index.html

Nuxt Static Generation Mismatch on Mobile

I'm experiencing a strange problem with Nuxt and Netlify with static generation on a JAMstack e-commerce.
I pushed my website on Netlify and everything went good, no error on console in the generation phase.
When i visit the generated site on desktop everything is fine and loaded correctly.
On mobile instead the content disappears! The dynamic content fetched from Prismic during generation won't load if navigate from the homepage (need to reload the page in order to view them).
I'll leave a netlify preview link of the build so you can experiencing the same problem.
Load the homepage (on mobile) and click the button "Shop Now", you'll see a page with no content; try reloading the page and everything will come back to normal.
I noticed that if you refresh or land in a page that it's not the homepage and start navigating the site everything works fine, so the problem only occurs when the start of navigation is from the homepage on mobile! Furthermore, if you land on the homepage, go to Shop Now, and then go back without reloading, even the content on the homepage disappear!
https://60352eb4c2e7180007325b89--leconturbanti.netlify.app/en
I can't understand why since there is no console error anywhere. While on desktop everything is fine. There's no css hide rule, no v-if for mobile, nothing. It seems like there's a bug on Nuxt hydration?
Anyone having the same problem?

Initial Navigation on CloudFront redirects to home

I have a gatsbyjs site which I host using S3 and CloudFormation.
If I navigate to the /blogs page, I always end up on the root page first. Navigation works fine afterwards.
On my machine using either gatsby develop or gatsby build && gatsby serve works. I can than naviagte to localhost:9000/blogs and see the blogs page.
When I deploy everything to a S3 Bucket (+CloudFront and a Domain) and navigate to quadroid.net/blogs I end up on the root page of my homepage.
I could not find any redirect in the networking tab of chrome.
Refreshing the page when viewing /blogs does again navigate to home.
Any clues why this might happen?
EDIT
The deployment is done using amplify publish --yes --invalidateCloudFront.
You need to set your Bucket to be public. And set the Origin and Origin Group. It's working for me.
Reference: public-s3-cloudfront-origin

A certain page won't load after deployment

I deployed my personal website using VueJs and Heroku. While you can see the homepage, when I click on the button that would take me to the Current Projects page, I get the following error :
"Cannot GET /CurrentProjects".
I can see this page on localhost, but not live. Has this ever happened to anyone? If so, what should I be looking out for. Any help is appreciated.

page refresh not working while using https

we have built UI using react js framework and html +css + js code is deployed inside apache 2. When I browse website it works fine but if I refresh page then I get 404. Can someone tell me how can I fix it.
Perhaps this answer is relevant to you:
Apache web server doesn't allow me to refresh on /about but on localhost its working fine
I know I also had problems related to HTML5 mode when first setting up react-router.
If you are using React-Router you are probably having this problem: React-router urls don't work when refreshing or writting manually.
You can also see the React Router tutorial for how to set up a production Express server.