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

    create folder in page : page\admin

    Framework
    4
    5
    265
    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.
    • E
      eloy.silva last edited by eloy.silva

      Hello friends, since I am new to this, and I would like your help, but what is the correct procedure, create a folder within the pages and create a .vue page, since when registering in the router it gives errors

      pages.jpg

      the error:

       ERROR  Failed to compile with 1 errors                                                                                                                                                        13:51:32
      This relative module was not found:
      
      * ../boot/axios in ./node_modules/babel-loader/lib??ref--1-0!./node_modules/@quasar/app/lib/webpack/loader.auto-import.js?kebab!./node_modules/vue-loader/lib??vue-loader-options!./src/pages/admin/UserSearch.vue?vue&type=script&lang=js&
      

      or everything must be contained within page

      best regards

      1 Reply Last reply Reply Quote 0
      • T
        turigeza last edited by

        In theory it should work. This is exactly how I have it working and I didn’t need to do anything special.

        A route in my case in router.js

        { path: 'herbs', components: { default: () => import('pages/herbs/herbs.vue'), left_drawer: () => import('pages/herbs/herbs_filters.vue') } },
        
        1 Reply Last reply Reply Quote 0
        • T
          tof06 last edited by

          @eloy-silva
          Look at the error message :

          This relative module was not found:

          • …/boot/axios

          It is looking for a ../boot/axios module relative to the current working directory, which is in your case pages/admin

          So, either import ../../boot/axios, or use the quasar’s defined src alias importing src/boot/axios

          E 1 Reply Last reply Reply Quote 0
          • E
            eloy.silva @tof06 last edited by

            @tof06
            Thanks

            is correct
            import { axiosInstance } from “…/…/boot/axios”;

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

              you don’t need to use relative path, boot folder is registered as an alias already. 'boot/axios' is enough.

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