-
Notifications
You must be signed in to change notification settings - Fork 47.2k
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
[Flight] Let environmentName vary over time by making it a function of string #29867
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
facebook-github-bot
added
CLA Signed
React Core Team
Opened by a member of the React Core Team
labels
Jun 12, 2024
gnoff
approved these changes
Jun 12, 2024
This lets the environment name vary within a request by the context it's being executed in. We could potentially also pass some information to it for context about what is being asked for.
That way if the environment changes inside a component we track what it was before entering and what it was after leaving.
This was referenced Jul 25, 2024
sebmarkbage
added a commit
that referenced
this pull request
Aug 30, 2024
We currently support the Environment Name change within a Component. #29867 If this happens, we give it two HoCs. The problem with this is that we only show one followed by `+1` in the list. Before: <img width="529" alt="Screenshot 2024-08-28 at 6 50 31 PM" src="https://github.com/user-attachments/assets/c080be72-c254-4d4d-89b6-d1b7f9a9ada8"> After: <img width="1101" alt="Screenshot 2024-08-28 at 7 16 21 PM" src="https://github.com/user-attachments/assets/04718674-164b-4255-9cf6-dec9198f12b7"> I could potentially instead badge this case as `A/B` in a single badge.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This lets the environment name vary within a request by the context a component, log or error being executed in.
A potentially different API would be something like
setEnvironmentName()
but we'd have to extend theReadableStream
or something to do that like we do for.allReady
. As a function though it has some expansion possibilities, e.g. we could potentially also pass some information to it for context about what is being asked for.If it changes before completing a task, we also emit the change so that we have the debug info for what the environment was before entering a component and what it was after completing it.