-
-
Notifications
You must be signed in to change notification settings - Fork 343
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
fix(next): ensure registry:ui components don't depend on themselves #1490
Conversation
|
built with Refined Cloudflare Pages Action⚡ Cloudflare Pages Deployment
|
This is more so an error in the component itself rather than in the CLI. No components should ever have a reference to itself. Pushing a fix momentarily |
Wouldn't it still be a good thing to check since this is an easy mistake to make? Maybe instead of ignoring it would give an error while building? |
I guess we could add a an error for it in the build script so we can catch it early on |
I think instead of removing it from the map it just reports an error and tries and help you along. Would you like to add it or should I give it a shot? |
haha guess we caught a few more! |
alright i think that's all of them |
Studs! |
fixes #1489
Previously if a component in the registry had a reference to itself it could add itself to its own registryDependencies. If not resolved correctly by the CLI this would result in stack overflows because of a circular dependency.
This PR fixes the CLI's handling of these circular dependencies as well as prevents them from being built into the registry by simply removing the component from it's own dependency array if it exists.