-
Notifications
You must be signed in to change notification settings - Fork 19
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
Use dynamic router basename. #821
Merged
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
Hyperkid123
force-pushed
the
dynamic-basename
branch
from
October 27, 2021 07:36
a015df4
to
f05f40b
Compare
Hyperkid123
force-pushed
the
dynamic-basename
branch
2 times, most recently
from
October 27, 2021 13:09
9d3be4f
to
8210559
Compare
cdcabrera
force-pushed
the
dynamic-basename
branch
from
October 27, 2021 13:31
8210559
to
2a73ac2
Compare
cdcabrera
added
bug
Something isn't working
platform
Contains, or is, platform specific work and issues
202112
project phase
labels
Oct 27, 2021
@Hyperkid123 just adjusted for
|
cdcabrera
approved these changes
Oct 27, 2021
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm!
cdcabrera
pushed a commit
that referenced
this pull request
Nov 29, 2021
cdcabrera
pushed a commit
that referenced
this pull request
Nov 29, 2021
cdcabrera
pushed a commit
that referenced
this pull request
Nov 30, 2021
cdcabrera
pushed a commit
that referenced
this pull request
Dec 6, 2021
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.
Fixes invalid router basename when switching between bundles.
How to produce
Go to prod-beta env and switch between insights/openshift subscription on from chrome left nav. The URL will have an incorrect bundle segment.
Changes
routerHelpers.dynamicBaseName
function to assign router basenameChrome is no longer disposing of the JS entry point of the remote module on each app/bundle switch. This means that "global" variables are not updated when we switch between modules common from the same remote container. Subscription has two modules, one for insights and one for openshift bundle.
Because the original
routerHelpers.baseName
is defined as a static constant in the entry file (webpack bundles it into the entry module because it is used in the remote entryAppEntry.js
), it is not updated when the application changes context from/insights
to/openshift
. It always keeps the initial value based on the initial bundle. This lead to the router having an invalid basename if the bundle was switched via client-side routing.