Repository localforage-module

randyhoulahan

randyhoulahan posted a new question

localforage-module • 13 days ago

How to do I make a PR for you to review?

I have updated your module to allow multiple instances via config. Also injected into Vuex. Excuse my ingnirance. Trying to save some minutes.

randyhoulahan

randyhoulahan posted a new question

localforage-module • 13 days ago

How to do I make a PR for you to review?

I have updated your module to allow multiple instances via config. Also injected into Vue. Excuse my ingnirance. Trying to save some minutes.

randyhoulahan

randyhoulahan posted a new question

localforage-module • 13 days ago

Feature
  • allow for multiple instances defined in config.
  • inject into vuex

I have done this. How can I do a PR for you to review?

besnikh

besnikh posted a new question

localforage-module • 2 months ago

How to use localForage with Vuex ?

Hi,

I am able to use local forage as a method, but I can not use it in store.. I tried different options but I could not manage to do it.

As a method, this is what I am doing

async localForage () {
      let data = {
        name: 'test',
        operation: 'Nav-Business'
      }
      await this.$localForage.setItem('nav', data)
        .then(data => {
          console.log('Working', data)
        })
        .catch(error => {
          console.log(error)
        })
    }

Thnx in advance

AndrewBogdanovTSS

AndrewBogdanovTSS posted a new question

localforage-module • 2 months ago

How to access localForage instance from the store?

I want to have access to localForage instance from the Nuxt store, but in provided docs I only found examples related to accessing the instance via this.$localForage in components, but how can it be accessed in store?

marceloavf

marceloavf posted a new question

localforage-module • 7 months ago

ReferenceError: localforage is not defined

Installed @nuxtjs/localforage normally

Actual code:

  modules: [
    // Doc: https://github.com/nuxt-community/axios-module#usage
    '@nuxtjs/axios',
    ['@nuxtjs/localforage', {
      driver: localforage.LOCALSTORAGE,
    }]
  ],

Error:

driver: localforage.LOCALSTORAGE,
            ^

ReferenceError: localforage is not defined
    at Object.<anonymous> (D:\xampp\htdocs\suporteps-extension\nuxt.config.js:56:13)
    at Module._compile (module.js:635:30)
    at Object.Module._extensions..js (module.js:646:10)
    at Module.load (module.js:554:32)
    at tryModuleLoad (module.js:497:12)
    at Function.Module._load (module.js:489:3)
    at Module.require (module.js:579:17)
    at require (internal/module.js:11:18)
    at exports.loadNuxtConfig.argv (D:\xampp\htdocs\suporteps-extension\node_modules\nuxt\bin\common\utils.js:18:15)
    at Object.<anonymous> (D:\xampp\htdocs\suporteps-extension\node_modules\nuxt\bin\nuxt-dev:63:20)
    at Module._compile (module.js:635:30)
    at Object.Module._extensions..js (module.js:646:10)
    at Module.load (module.js:554:32)
    at tryModuleLoad (module.js:497:12)
    at Function.Module._load (module.js:489:3)
    at Module.require (module.js:579:17)
error An unexpected error occurred: "Command failed.