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

    Cordova undefined on iOS

    Help
    6
    26
    10400
    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.
    • A
      arddor last edited by

      Hello,

      I’m trying to use Quasar to build an App for iOS and Android using the Barcode plugin. Android works without a Problem, however on iOS i always get ReferenceError: Can't find variable: cordova. I’m trying the following on button press:

      cordova.plugins.barcodeScanner.scan(
      function (result) {
          alert("We got a barcode\n" +
                "Result: " + result.text + "\n" +
                "Format: " + result.format + "\n" +
                "Cancelled: " + result.cancelled);
      },
      function (error) {
          alert("Scanning failed: " + error);
      }
      );
      

      I tested it with Simulator and Device and the problem occurs with both. Do I have to somehow register the cordovavariable?

      1 Reply Last reply Reply Quote 0
      • Dobromir
        Dobromir last edited by

        try window.cordova

        1 Reply Last reply Reply Quote 0
        • A
          arddor last edited by

          Unfortunately that does also not work for me

          1 Reply Last reply Reply Quote 0
          • rstoenescu
            rstoenescu Admin last edited by

            Hi, will look into it.

            1 Reply Last reply Reply Quote 0
            • Martin
              Martin last edited by Martin

              I’m having the same error. App works ok on android but cordova is not recognised on iOS
              pre-fixing with window doesn’t help.

              Quasar 0.9

              1 Reply Last reply Reply Quote 0
              • rstoenescu
                rstoenescu Admin last edited by

                Root caused it. Will fix it.

                1 Reply Last reply Reply Quote 1
                • rstoenescu
                  rstoenescu Admin last edited by rstoenescu

                  Fixed in Quasar edge and will be available in v0.12.1. Thanks for reporting guys!
                  Reference: https://github.com/quasarframework/quasar/issues/316

                  Martin 1 Reply Last reply Reply Quote 0
                  • Martin
                    Martin last edited by

                    Thanks! Using yesterday’s edge. Works ok and stable. Almost ready to start alpha testing my app in the apple.android stores 🙂

                    1 Reply Last reply Reply Quote 1
                    • s.molinari
                      s.molinari last edited by

                      Cool! Hope you let us in on its release (if possible)!

                      Scott

                      Martin 1 Reply Last reply Reply Quote 0
                      • Martin
                        Martin @s.molinari last edited by

                        @s.molinari Surely I will.

                        1 Reply Last reply Reply Quote 0
                        • Martin
                          Martin @rstoenescu last edited by

                          @rstoenescu Is it possible to get a branch from v12.0 with the cordova fix? Or maybe just the code snippet (if it’s an easy fix)
                          Some Modals and popups don’t seem to work with yesterday’s quasar-edge.
                          (haven’t tried today)
                          thanks.

                          1 Reply Last reply Reply Quote 0
                          • rstoenescu
                            rstoenescu Admin last edited by

                            @Martin oh? I’m really interested in what the problems are. Wanna release v0.13 this or next week (depending on how much time I have). Skipped v0.12.1 because edge version contains sooo many novelties and enhancements.

                            Martin 1 Reply Last reply Reply Quote 0
                            • Martin
                              Martin @rstoenescu last edited by

                              @rstoenescu ok, I’ll try again today with latest edge and see if I can give you something reproducible.

                              1 Reply Last reply Reply Quote 0
                              • Martin
                                Martin last edited by

                                I’m getting a null error when closing a Modal. After that it’s not possible to open it again.
                                I’ll try to set up a simple example that reproduces this.
                                0_1484831570590_upload-64cc3568-f4e5-4cc8-a60b-53a854fa4910

                                0_1484831785795_upload-18e169bf-e401-4c01-9931-40e81153c300

                                1 Reply Last reply Reply Quote 0
                                • Martin
                                  Martin last edited by

                                  At first I thought it was related to my cordova security settings, but that’s fixed.
                                  Now I’m only getting this error
                                  "TypeError: Cannot read property ‘removeChild’ of null
                                  at VueComponent.beforeDestroy "
                                  The same error also appears with PopOvers.
                                  Searching on Google gave me this link (a vue-material issue with md-tooltips)
                                  with similar error.
                                  https://github.com/marcosmoura/vue-material/issues/188

                                  1 Reply Last reply Reply Quote 0
                                  • rstoenescu
                                    rstoenescu Admin last edited by

                                    @Martin Ok, now I know what’s this about. Can you share your repo to see the exact use case of your Modal pls? A private link or something. You’re on an edge case and I’d like to fix that also. Thanks!

                                    1 Reply Last reply Reply Quote 0
                                    • Martin
                                      Martin last edited by

                                      Ok I’ve set up a rep for you. What email address can I send the link to?

                                      1 Reply Last reply Reply Quote 0
                                      • rstoenescu
                                        rstoenescu Admin last edited by

                                        razvan.stoenescu@gmail.com

                                        1 Reply Last reply Reply Quote 0
                                        • rstoenescu
                                          rstoenescu Admin last edited by

                                          Oops, “The owner of this repository (skilldance) is already at their plan limit and will need to upgrade before adding more users.”

                                          1 Reply Last reply Reply Quote 0
                                          • rstoenescu
                                            rstoenescu Admin last edited by

                                            Ok, discussed with Martin in private. He helped me reproduce his use case and pushed fix for it. Quasar edge has it and v0.13 (next immediate version) will too.

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