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: issue cause by using Router from next/routes on the server #368

Merged
merged 1 commit into from
Oct 9, 2018

Conversation

mikemurray
Copy link
Member

Resolves #348
Impact: critical
Type: bugfix

Issue

Refreshing on pages that use search queries, like the product grid, causes the app to crash due to trying to access Router on the server.

Solution

Use the Router on the client (browser) only by placing it within an "is browser" conditional.

Breaking changes

none

Testing

  1. With sample data loaded to be able to test other tag grids
  2. Navigate to another grid via the menu
  3. Page should load
  4. Refresh the page manually
  5. The page should load properly
  6. Ensure query params are properly applied to the page. (number of items per page, the current page, and other filters)

  1. Disable javascript
  2. Ensure query params are properly applied to the page in SSR mode. (number of items per page, the current page, and other filters)

@rosshadden rosshadden merged commit 1ed61cd into develop Oct 9, 2018
@rosshadden rosshadden deleted the fix-348-mikemurray-router-error branch October 9, 2018 19:40
This was referenced Jan 15, 2019
@spencern spencern mentioned this pull request Jan 25, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Error on tag page when refreshing or navigating directly to one
2 participants