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

fix: infinite playground rendering #4031

Merged
merged 2 commits into from
Jun 21, 2023
Merged

Conversation

kwasniew
Copy link
Contributor

About the changes

Env array was causing infinite re-render

Important files

Discussion points

@vercel
Copy link

vercel bot commented Jun 21, 2023

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
unleash-monorepo-frontend ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jun 21, 2023 9:43am
1 Ignored Deployment
Name Status Preview Comments Updated (UTC)
unleash-docs ⬜️ Ignored (Inspect) Jun 21, 2023 9:43am

Copy link
Contributor

@andreas-unleash andreas-unleash left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LG

@@ -37,7 +37,7 @@ export const Playground: VFC<{}> = () => {

useEffect(() => {
setEnvironments([resolveDefaultEnvironment(availableEnvironments)]);
}, [environments]);
}, [JSON.stringify(environments)]);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should be availableEnvironments

@kwasniew kwasniew merged commit 50d4de8 into main Jun 21, 2023
16 of 17 checks passed
@kwasniew kwasniew deleted the fix-infinite-playground-rendering branch June 21, 2023 09:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

None yet

2 participants