GithubHelp home page GithubHelp logo

Comments (11)

bvaughn avatar bvaughn commented on May 21, 2024 1

Ah. I believe this is actually a service-worker issue. (Mobile Safari doesn't support them.)

Looking a little more closely at this, curl https://personal-logger.now.sh/foods returns a 404 response, which is consistent with what I'm seeing on mobile.

That same URL in (desktop) Chrome is handled by the service worker, which is what redirects it to the SPA.

from personal-logger.

bvaughn avatar bvaughn commented on May 21, 2024 1

I tried following the Now create-react-app guide and using serve for routing, but this caused my deploys to start failing with an out of memory error. This might be due to the fact that I'm on the cheapest plan.

For now, I think I'll just fix this by replacing the BrowserRouter with the HashRouter.

from personal-logger.

bvaughn avatar bvaughn commented on May 21, 2024 1

Resolved via d5ad60c

from personal-logger.

ishankbahl avatar ishankbahl commented on May 21, 2024

Hey @bvaughn , wasn't able to recreate the bug on my device. Direct navigation didn't break anything.

from personal-logger.

bvaughn avatar bvaughn commented on May 21, 2024

Really! So you can successfully eg delete things?

This consistently 404s for me, on device and simulator

from personal-logger.

ishankbahl avatar ishankbahl commented on May 21, 2024

Was able to delete things successfully.

from personal-logger.

bvaughn avatar bvaughn commented on May 21, 2024

Strange. Any time I try to create a new item, or delete one, or navigate to any page other than the root URL- I get a 404 back. This happens on my iPhone for Chrome and Safari, and on my simulator for Safari.

from personal-logger.

robertcoopercode avatar robertcoopercode commented on May 21, 2024

I've managed to reproduce the bug on my iPhone 8 using Chrome. If I refresh a page or try deleting an item, I get a 404.

from personal-logger.

bvaughn avatar bvaughn commented on May 21, 2024

👍

I see that behavior in all of my iOS browsers, on all iOS devices/simulators.

from personal-logger.

bvaughn avatar bvaughn commented on May 21, 2024

Confirmed by visiting https://personal-logger.now.sh/foods on Chrome in Android. Got the 404 response. Then visited https://personal-logger.now.sh before retrying https://personal-logger.now.sh/foods and it worked the second time (because the service worker had been installed).

from personal-logger.

bvaughn avatar bvaughn commented on May 21, 2024

So I think the solution to this is to configure Now to do a 404 redirect for me.

from personal-logger.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.