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

    [SOLVED] Working with cordova plugins in Quasar

    Help
    1
    2
    869
    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.
    • yev
      yev last edited by yev

      I’m new to quasar (I’m using v0.15) and cordova, I need to use a certain plugin: Insomnia.

      What’s the best practice or recommended approach in using such plugins within Quasar?

      After adding the plugin, I need to use the actual api by invoking window.plugins.insomnia.keepAwake(), I was wondering where should Implement this? Will this be automatically available in my app upon adding the plugin, or should I cd in to src-cordova and implement it there?

      Lastly, I take it that whatever the approach was, would work to all cordova plugins that I would need to add in the future?

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

        Was able to solve this, Razvan gave me a link when I inquired on the gitter channel: Cordova Plugins This will surely be available upon the release of v0.15 docs.

        Although I encountered some problems as well,

        • Plugin’s codes didn’t work whenever I used it on App.vue but it worked on other vue files. This must be a vue or vue template thing, just haven’t got the time to figure it out. Maybe you guys know the answer.
        • I’m using cordova run to make my changes ‘persist’. Using quasar dev -m cordova won’t really work when the device is not plugged in. I have to do a quasar build -m cordova before I run cordova run though or else changes that I see on quasar dev -m cordova will not reflect.

        Again, there might a proper way of doing this. Things will probably get clearer when v0.15 docs came out.

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