-
Notifications
You must be signed in to change notification settings - Fork 0
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
feat: use sessionStorage to save state of filters #751
Conversation
✅ Deploy Preview for gatsby-theme-project-portal-defaults ready!
To edit notification comments on pull requests, go to your Netlify site configuration. |
✅ Deploy Preview for gatsby-theme-project-portal-ex-site ready!
To edit notification comments on pull requests, go to your Netlify site configuration. |
✅ Deploy Preview for project-portal-storybook ready!
To edit notification comments on pull requests, go to your Netlify site configuration. |
…/project-portal-theme into feat-project-page-save-state
Note: This comment gets updated with every commit 713f80ebd9ae8a78de64e117f64695aab8eeefe7 example-site |
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.
This works with the filters! Nice.
How easy would it be to include the results page number in here, so when you hit back it loads the page you were just on?
If it's easy, we could add that, if not let's make that into a separate Issue (and write down anything we know about the problem, any pitfalls we'd need to solve) and hand it over to the new keepers of the portal.
packages/gatsby-theme-project-portal/src/components/SearchBar.tsx
Outdated
Show resolved
Hide resolved
packages/gatsby-theme-project-portal/src/components/SearchBar.tsx
Outdated
Show resolved
Hide resolved
packages/gatsby-theme-project-portal/src/components/SearchBar.tsx
Outdated
Show resolved
Hide resolved
Hey John, thanks for the review/comments. So this is what Heather and I have been trying to tackle recently. To summarize quickly, it's hard for us to differentiate when a projectPage is being loaded because of
This is because of the use of useEffect hooks and useState variables. I think, as you suggest, it may be better to exclude storing page in the session in this PR and get this merged in. I can put in another issue documenting the challenge with adding page number. Again, thanks for taking a look! |
That sounds great. Thanks, Josh! |
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.
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.
I reran prettier locally – I think yours was configured differently. Looks good now!
Thank you! Merging this in. |
No description provided.