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

    Property '$q' does not exist on type

    Framework
    3
    4
    1237
    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.
    • D
      diadal last edited by

      how to access this.$q under setup()

      <script lang="ts">
      // import { LoadingBar } from 'quasar'
      import { defineComponent, onMounted } from '@vue/composition-api'
      
      export default defineComponent({
        name: 'AuthLayout',
        setup () {
            onMounted(() => {
              this.$q.loadingBar.stop()
              console.log('mounted!')
      
              })
          return { }
        }
      })
      </script>
      
      metalsadman 1 Reply Last reply Reply Quote 1
      • metalsadman
        metalsadman @diadal last edited by metalsadman

        @diadal pass the context argument(2nd) setup(props, context) … context.root.$q.

        D 1 Reply Last reply Reply Quote 1
        • D
          diadal @metalsadman last edited by

          @metalsadman said in Property '$q' does not exist on type:

          context.root.$q

          yah it works

          1 Reply Last reply Reply Quote 1
          • D
            DaniloBarros last edited by

            This post is deleted!
            1 Reply Last reply Reply Quote 0
            • First post
              Last post