-
Notifications
You must be signed in to change notification settings - Fork 18
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
3 of 4 - refactor(router): sw-625 move to router v6 #989
Conversation
As of 20221207 rebased and updated. Confirmed working both locally, and through the proxy against stage-beta. We'll need to optimize how the route configs are being pulled since there looked like lag coming through the page loads, but that could also be associated with the proxy. The route configs don't change, once loaded, so caching them on an extended cache cycle might become a thing |
a051152
to
4f12d89
Compare
* routerContext, useRedirect hook
* routerContext, useLocation hook
* routerContext, useLocation hook
6dddd45
to
50a1296
Compare
Codecov Report
Additional details and impacted files@@ Coverage Diff @@
## dev #989 +/- ##
==========================================
- Coverage 93.65% 93.52% -0.14%
==========================================
Files 121 123 +2
Lines 4052 4138 +86
Branches 1633 1679 +46
==========================================
+ Hits 3795 3870 +75
- Misses 240 251 +11
Partials 17 17
Continue to review full report at Codecov.
|
* build, routing package, module ref, spelling * configs, sorted products, aliases, simplify routes * locale, OpenShift strings * AppEntry, remove router component * app, locale loading checks * helpers, add memoize, object freeze * authenticationContext, remove nav history push * i18n, minor check to avoid reload * productView, useRouteDetail hook update * productViewMissing, add useNavigate, RouteDetail hooks * redux, viewReducer, appTypes for storing route ref * router, simplify, useSetRouteDetail for config load * routerContext, useRouteDetail, wrap location, navigate * routerHelpers, restructure getRouteConfigByPath, memo
/retest |
* build, routing package, module ref, spelling * configs, sorted products, aliases, simplify routes * locale, OpenShift strings * AppEntry, remove router component * app, locale loading checks * helpers, add memoize, object freeze * authenticationContext, remove nav history push * i18n, minor check to avoid reload * productView, useRouteDetail hook update * productViewMissing, add useNavigate, RouteDetail hooks * redux, viewReducer, appTypes for storing route ref * router, simplify, useSetRouteDetail for config load * routerContext, useRouteDetail, wrap location, navigate * routerHelpers, restructure getRouteConfigByPath, memo
What's included
Notes
:productPath
. This parameter is "kind-of" superfluous due to the use of a noticeably quicker way of loading product configuration by handlingwindow.location.pathname
directly within the newrouterContext.js
hooks androuteHelpers.js
useSetRouteDetail
andHow to test
Coverage and basic unit test check
$ yarn
$ yarn test
Check the build
$ yarn
$ yarn build
Example
...
Updates issue/story
swatch-625
related #1048 #1045