Created
July 28, 2015 08:48
-
-
Save totya24/a7711da0dd8bc1aa3787 to your computer and use it in GitHub Desktop.
localForage example
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// localStorage használatával | |
localStorage.setItem('key', JSON.stringify('value')); | |
doSomethingElse(); | |
// localForage esetén használhatunk callback függvényt: | |
localforage.setItem('key', 'value', doSomethingElse); | |
// vagy "promises" megoldást: | |
localforage.setItem('key', 'value').then(doSomethingElse); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment