code: function setLocalStorageItem(key, value) {
    window.localStorage.setItem(key,
      JSON.stringify(value)
    );
  }
docs: Set a value of any type in localStorage.
  (Serializes in JSON before storing since Storage objects can only hold strings.)
  
  @param {String} key   Key in localStorage
  @param {*}      value The value to set