x-show with local storage value don't work

Viewed 19

I have the element with x-show="localStorage.getItem('hi') == 'hi'". When I change value like localStorage.setItem('hi', 'hello'), The element should be hidden, but it doesn't hide. How can I make the element hide?

0 Answers
Related