Skip to content

Troublesome conditional rendering in Header #3

Description

@moralesbang

I have been studying your screen cast and posts by jwt_sessions gem's author. There are many interesting topics wrapped in this "let's build'. Trying of build header I found a issue when you're trying to show some buttons depending of signedIn state, because the localStorage isn't reactive. When someone sign in or log out, that person need to refresh the page so that correct behavior in header happens. I read about possible solutions and all of them looks some tricky. I decided to use Vuex for manage that state. A solution simple, short and efficient.

PD: I love your videos. That has motivated me to growth a lot in RoR 😄 ✌️

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions