Closed
Description
At the end of the base example it says:
You could also store a date representing when the values were stored. With that metadata, the mounted method could make a logical call on whether or not to store the values again, such as in this version below. You can try this version below.
But in the example the mounted method only do:
if(localStorage.name) this.name = localStorage.name;
if(localStorage.age) this.age = localStorage.age;
The mounted method only check if the values exist, it never "make a logical call on whether or not to store the values again".