Skip to content
This repository has been archived by the owner on Aug 23, 2024. It is now read-only.

yangga/react-native-sync-localstorage

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

react-native-localstorage

None async local storage

[Installation]

npm install --save react-native-sync-localstorage

[Usage]

1. Loading stored values at beginnig

import localStorage from 'react-native-sync-localstorage'

...

localStorage.getAllFromLocalStorage()
  .then(() => {
    // Do Something after loading...
  })
  .catch(err => {
    console.warn(err)
  })

2. Use local storage comfortable

2-1. Setting

const value = 12345
localStorage.setItem('key', value)

2-2. Getting

localStorage.getItem('key')

2-3. Deleting

localStorage.removeItem('key')

About

None async local storage

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published