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
    1. Home
    2. Misaosama
    M
    • Profile
    • Following 0
    • Followers 0
    • Topics 1
    • Posts 2
    • Best 0
    • Groups 0

    Misaosama

    @Misaosama

    0
    Reputation
    1
    Profile views
    2
    Posts
    0
    Followers
    0
    Following
    Joined Last Online

    Misaosama Follow

    Latest posts made by Misaosama

    • How to use `cordova-plugin-universal-links` to create universal link for cordova app

      I’m developing a cordova app using quasar framework and I’m trying to add universal link to the app using cordova-plugin-universal-links. Here is the documentation: https://github.com/eldadfux/cordova-plugin-universal-links. This plugin export an module universalLinks to help subscribe universal link event.
      However, I’m not sure how to subscribe event using universalLinks module. I was trying to add codes like this:

      <template>
          ...some html code...
      </template>
      
      <script>
      // import { universalLinks } from 'cordova-plugin-universal-links'
      export default {
        name: 'default',
        components: {
        },
        data () {
          return {
          }
        },
        mounted () {
          var app = {
            // Application Constructor
            initialize: function () {
              this.bindEvents()
            },
      
            // Bind Event Listeners
            bindEvents: function () {
              document.addEventListener('deviceready', this.onDeviceReady, false)
            },
      
            // deviceready Event Handler
            onDeviceReady: function () {
              console.log('Device is ready for work')
              // window.universalLinks.subscribe('openApp', function (eventData) {
                universalLinks.subscribe('openApp', function (eventData) {
                console.log('openApp.')
                // do some work to show list of news
              })
            }
          }
          app.initialize()
          // await this.$store.dispatch('common/loadPredefinedScreens')
        }
        }
      }
      </script>
      

      https://quasar.dev/quasar-cli/developing-cordova-apps/cordova-plugins
      Here is the quasar documentations for using cordova plugins. However, when I try to run and build the app, it post an error saying universalLinks not defined, and then I tried to use window.universalLinks but it does not work either. According to quasar documentation, cordova module should be injected into window, but it does not work.
      Anyone can help to tell me how quasar framework uses cordova-plugin-universal-links

      posted in Help
      M
      Misaosama
    • RE: How i use events of cordova deeplinks plugin?

      @rstoenescu When I try to subscribe the event using universalLinks.subscribe() it post error saying 'universalLinks' is not defined. I wonder how I can import universakLinks from cordova-plugin-universal-links.

      posted in Help
      M
      Misaosama