-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Don't lose selected job category on re-render (#658)
This is a second fix for the same issue in #656. This doesn't require our callers to be as careful to pass identical props. - Simplify our querying of job category suggestions. Previously we were using a lazy query and then immediately invoking the query with a `useEffect`. This defeats Apollo's ability to avoid rerunning identical queries. - Don't reset our selection on every render if the state already contained a selected job category.
- Loading branch information
Showing
3 changed files
with
25 additions
and
25 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
--- | ||
'wingman-fe': patch | ||
--- | ||
|
||
**JobCategorySuggest:** Don't lose selected job category on re-render | ||
|
||
If the user selects a job category their selection will now be preserved when the component re-renders. |
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
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