Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

377
Views
Quasar Vue 3 route.push() not a function

When I try to route to another page in js I get the error:

Uncaught TypeError: route.push is not a function

code snippit:

    import { useRoute } from "vue-router";
    const route = useRoute();

    function openApp() {
        route.push("/#/home");
    };

when I use anchor tag around a btn the routing works

<a href="/#/home">
    <q-btn class="q-ma-md" color="primary" icon="check" label="OK" />
</a>

Any Ideas, Thanks

about 4 years ago · Juan Pablo Isaza
1 answers
Answer question

0

There is a difference between useRoute and useRouter

Try this:

import { useRouter } from "vue-router";
const router = useRouter();
router.push("/#/home");
about 4 years ago · Juan Pablo Isaza Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!