No More Posting New Topics!

If you have a question or an issue, please start a thread in our Github Discussions Forum.
This forum is closed for new threads/ topics.

Navigation

    Quasar Framework

    • Login
    • Search
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search

    Capacitor routes won't change when building iOS applicaiton

    Help
    3
    6
    358
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • J
      jsloan last edited by

      When developing and testing my application using capacitor things work perfect, but when I use the build command I cannot get the application to change routes on the emulator or when pushed to TestFlight. Have I missed something? Has anyone else had this experience?

      1 Reply Last reply Reply Quote 0
      • G
        g_hult last edited by

        I am facing a similar problem on iOS with capacitor routing right now actually. I’m using router hash mode and on initial load the url is capacitor://localhost# instead of capacitor://localhost/#. So there is no trailing slash initially which breaks things. Sometimes when I navigate around this gets corrected. I tried setting PUBLIC_PATH=capacitor://localhost/ but it doesn’t seem to work.

        Working on a fix now, but I think at least in my case it has to do with the trailing slash

        J 1 Reply Last reply Reply Quote 1
        • J
          jsloan @g_hult last edited by

          @g_hult Thank you very much for this! I will see what I can be done about it, but perhaps I may have to delay my release. I will tinker with it now with this is mind and let you know if I uncover anything. Thanks again!

          dobbel 1 Reply Last reply Reply Quote 0
          • dobbel
            dobbel @jsloan last edited by

            @jsloan @g_hult

            Please create a github issue for this.

            J 1 Reply Last reply Reply Quote 1
            • J
              jsloan @dobbel last edited by

              @dobbel Done!

              1 Reply Last reply Reply Quote 0
              • G
                g_hult last edited by g_hult

                I made a workaround / hack for now on iOS with this line on my initial page.

                created(){
                  if(this.$q.platform.is.ios){
                     this.window.location = "capacitor://localhost/#/"
                  }
                }
                

                At least that solves the urgent issue for now and sets the trailing slash correctly to “/#/” for all subsequent navigations.

                1 Reply Last reply Reply Quote 1
                • First post
                  Last post