Skip to content
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] when I tried to open the UI page, the service reported a 404 error #47

Open
GrinZero opened this issue Dec 28, 2024 · 7 comments
Open

Comments

@GrinZero
Copy link

Desc

Today I added a menu field to the manifest and added commands to it:

image

And when I finish my code and run it:

image

I found that every time I try to open the plugin UI, a web server-side 404 error appears directly:

image
image

@GrinZero
Copy link
Author

Just one more piece of information, this is a monorepo project

@gavinmcfarland
Copy link
Owner

Thank you for reporting this. Would you mind posting a screenshot of the part of the manifest that has the ui and main fields? And then I should be able to take it from there.

Thanks again!

@GrinZero
Copy link
Author

I have identified the key issue.
image
Currently, there are no issues with using tmp/index.html in the code in single repository mode. But when in the monorepo repository, as a sub repository, plugma may be installed in the outermost node_modules, which can cause the position of the tmp folder to be abnormal and result in the inability to find the tmp/index.html file during actual code execution

This is a pr to fix it: #48

@GrinZero
Copy link
Author

Since Rollup does not accept relative or absolute paths, I chose to fix this issue by copying the folder to the correct path

@gavinmcfarland
Copy link
Owner

Thank you I'll review your PR in the next couple of weeks.

@gavinmcfarland
Copy link
Owner

I was just reviewing your PR and I wondered if you had an example monorepo of this you could share? It would be useful to be able to test and also to see how you're using Plugma with a monorepo. Many thanks!

@GrinZero
Copy link
Author

I'll prepare a demo later.👌In fact, I started with the initial project of turbo + pnpm

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants