I used to be able to do this in the old editor, but I'm having problems in the new one. I'm trying to setup some local storage variable default values when the app launches. Here's the code I've tested and none of it works. I've even tried putting it in a setTimeout() function to no avail.
if(!localStorage.onlineStatus localStorage.onlineStatus === null localStorage.onlineStatus = '') {
localStorage.onlineStatus = '0'
}
What am I doing wrong? How can I setup a default value? TIA