store boolean values as json in localStorage
store view state in the storage