-
Notifications
You must be signed in to change notification settings - Fork 17
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Bug]: Extension doesn't work when nuxt project is in a sub folder of the workspace #49
Comments
Hello @MartinTruRating, To be clear, your issue now is not being able to install dependencies ? |
I encountered the same problem, when Workspace mode is enabled, Nuxtr recognizes the first item in the workspace by default, and when my project is not ranked first in the workspace, Nuxtr does not recognize the item I need, and currently I can only fix this problem when I move my project to the first place |
@Administrator-M can you elaborate more about "my project is not ranked first in the workspace" ? |
@adhamfarrag Hello, yeah so the It's like we need a combination of the two in a setting where you can specifiy the |
@MartinTruRating have you tried using |
@adhamfarrag I did, so that then worked (as in I could use it to create components etc), but the problem then was when I tried to install/update any dependencies, it tried doing it in the folder above the src folder (which in a monorepo setup would be fine as the modules get installed into the root) rather than within the I've added the following rough directory structure if this helps at all
|
Got it.. I will refactor monorepo features and release it as soon as I can. |
Brilliant, thank you very much! Make sure you still keep the monorepo functionality/compatibility for those that want to use that feature as I've used it on different projects :) |
@adhamfarrag Thanks for your awesome work on this! To add more info regarding the issue faced by @Administrator-M, when we create Multi-root Workspaces if the first folder has a different project, then all the features provided by Nuxtr are not available. For example, if the multi-root workspace is like this, it works The reason for using this approach is both has different language/framework and have their own source control. They are just grouped using the multi-root workspace approach to avoid switching windows. |
Experiencing the same issue. Here's my project structure:
|
I have the same structure, and I'd love to use Nuxtr with the file creation templates it offers, but in my monorepo it won't activate... |
I ran into the same issue with my monorepo, but I’ve already fixed it. Here’s how I did it: 📦 monorepo-main Hope that helps! Let me know if you need more details. |
Environment
Nuxt project info:
What went wrong?
I was trying to use nuxtr when my nuxt project lives within a subfolder within the workspace (ie
/src
). But it cannot find it (see belowIs there a config setting that allows it to set the root dir of nuxtr so it can then pick everything up and work?
I tried using the monorepo
DirectoryName
config setting set to/src
which enabled the extension and worked for things like creating components/stores etc but didn't for installing deps because it was trying to use the workspace root which is correct for a monorepo setup.How to reproduce it?
Install nuxt into a subfolder structure like this:
![image](https://private-user-images.githubusercontent.com/93127087/269659381-e5389679-a35e-4b03-8cf1-cc605cfb71c7.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3Mzg4ODU3MzEsIm5iZiI6MTczODg4NTQzMSwicGF0aCI6Ii85MzEyNzA4Ny8yNjk2NTkzODEtZTUzODk2NzktYTM1ZS00YjAzLThjZjEtY2M2MDVjZmI3MWM3LnBuZz9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNTAyMDYlMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjUwMjA2VDIzNDM1MVomWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPTA0YTUyNWUzM2M2OTFjOTcwNmU4ZjBiNDllOTI4YjAwY2Q0YTNjMzcwY2IwNGMxYmYzMzRmZjViZWQ4NGY3ZjAmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0In0.rH1BbE04EEWQb_0is07E3Tlrzt1jFYIZtRKaM9nRMBY)
Nuxtr isn't available in the sidebar or command pallete
The text was updated successfully, but these errors were encountered: