I’m currently building an app in which the user presses a button and this changes the innerhtml of an element. What I want to happen is the user to only have to press the button once and every time they load the web app on their device, it changes to the innerhtml stored in their local storage.
I’ve seen an example on here where a user can use local storage to store the scene (thanks @DBear) but I can’t find anything for storing the value, in my case innerhtml, of an element.
Can anyone help with this? I’ve never used local storage before,
I’ve worked out how to do this! Just create a variable with the local storage tag, link this to the element you want to change and run the javascript upon screen load. Here’s an example of this: