How to use the quasar.LocalStorage.remove function in quasar

To help you get started, we’ve selected a few quasar examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github zuck / alighieri / src / components / Writer.vue View on Github external
updateContentAndStats () {
      this.content = this.convertHtmlToTxt(this.contentHTML)
      // Store backup content (only if there is valid text)
      if (this.content && this.content.length > 0) {
        LocalStorage.set(CONTENT_BACKUP_KEY, this.contentHTML)
      }
      else {
        LocalStorage.remove(CONTENT_BACKUP_KEY)
      }
      this.sentences = this.content
        .replace(/(\.+|:|;|\?|!)/g, '$1\n')
        .split(/\n+\s*/)
        .filter(n => n)
      this.words = this.content
        .split(/\s+/)
        .filter(n => n)
    },
    processEditOperation (operation) {
github zuck / alighieri / src / store / index.js View on Github external
updateStats: debounce(state => {
      state.content = convertHtmlToTxt(state.contentHTML)
      state.sentences = state.content
        .replace(/(\.+|:|;|\?|!)/g, '$1\n')
        .split(/\n+\s*/)
        .filter(n => n)
      state.words = state.content.split(/\s+/).filter(n => n)
      if (state.words) {
        LocalStorage.set(CONTENT_BACKUP_KEY, state.contentHTML)
      } else {
        LocalStorage.remove(CONTENT_BACKUP_KEY)
      }
    }, 100 /* Execute at most once every 100ms */)
  },
github quasarframework / quasar / quasar / dev / components / other / web-storage.vue View on Github external
toggle (key) {
      if (LocalStorage.has(key)) {
        LocalStorage.remove(key)
      }
      else {
        LocalStorage.set(key, `${key}-value`)
      }
      this.update()
    },
    clear () {
github sharpshark28 / my_spells / src / store.js View on Github external
LocalStorage.remove('chosen')
      break
    case 'CHANGE_CHOSEN':
      if (action.data.want) {
        state.chosen.push(action.data.id)
      }
      else {
        let index = state.chosen.indexOf(action.data.id)
        if (index >= 0) state.chosen.splice(index, 1)
      }

      if (state.chosen.length) {
        LocalStorage.set('chosen', state.chosen.join(','))
      }
      else {
        LocalStorage.remove('chosen')
      }
      break
    case 'SEARCH_CHANGED':
      state.page = 1
      break
  }
}