Skip to content
This repository has been archived by the owner on Jan 6, 2024. It is now read-only.

Support for unplugin-vue-router #57

Open
Ragura opened this issue May 30, 2023 · 3 comments
Open

Support for unplugin-vue-router #57

Ragura opened this issue May 30, 2023 · 3 comments
Labels
T: feature Typpe: New feature or request

Comments

@Ragura
Copy link

Ragura commented May 30, 2023

First of all, thanks for building this extension!

In our project we are using unplugin-vue-router which generates pages according to a folder/file structure and syntax, much like it does for Nuxt. This does not get picked up by the tools (router tab says router is not installed). Is there anything you could do on your side to support this?

@webfansplz
Copy link
Owner

Can you provide a mini repo? 🙏 (I've tested unplugin-vue-router in playground, It's work fine.)

@Ragura
Copy link
Author

Ragura commented May 31, 2023

It appears to be related to how our components/routes are set up and not directly because of unplugin-vue-router. Upon further testing the routes show up after some navigation has occurred (the route is no longer just localhost:3000), but not when the app has just loaded. The App.vue file contains this:

<component :is="$route.meta.layout === 'full-screen' ? LayoutFullSreen : LayoutDefault" />
<LogReport />

This renders the layout component which has a <router-view> component within a <suspense> component within a <main> tag with Element Plus' v-loading directive attached. The login page then renders, but the routes still don't show up. All this time the only component that is displayed in the component inspector is <ElLoading> (An Element Plus loading component).

Only after navigating to a route like /assignments do all the routes and components suddenly pop up in the list. Honestly, this isn't a big deal and is probably very specific to our project.

I'm sorry I can't provide a small reproduction, because it seems to be very tightly related to our (rather complicated) App set up.

@bkoplin
Copy link

bkoplin commented Jun 1, 2023

I use ElementPlus's v-loading directive and noticed the same exact issue, @Ragura.

@alexzhang1030 alexzhang1030 added the T: feature Typpe: New feature or request label Jun 30, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
T: feature Typpe: New feature or request
Projects
None yet
Development

No branches or pull requests

4 participants