Uploaded image for project: 'Realm JavaScript SDK'
  1. Realm JavaScript SDK
  2. RJS-2593

[@realm/react] Update the user reference from `useUser()` on each update

    • Type: Icon: Bug Bug
    • Resolution: Fixed
    • Priority: Icon: Minor - P4 Minor - P4
    • None
    • Affects Version/s: None
    • Component/s: Realm React
    • None

      Currently, the User reference returned by useUser() will be updated only when the ID is updated.

      To more easily react to changes when e.g. the access token is refreshed or the user profile is updated, we could instead update the user on each invocation of the user listener.

      This would make useUser() behavior similarly to useQuery() in terms of rerendering.

            Assignee:
            andrew.meyer@mongodb.com Andrew Meyer
            Reporter:
            unitosyncbot Unito Sync Bot
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: