0.13.0 • Published 4 years ago

@seald-io/sdk-plugin-localstorage v0.13.0

Weekly downloads
-
License
UNLICENSED
Repository
-
Last release
4 years ago

@seald-io/sdk-plugin-localstorage

This module is a plugin for the Seald SDK : @seald-io/sdk.

⚠️ This module is deprecated. You probably want to use a persistent database instead: see https://docs.seald.io/en/sdk/guides/4-identities.html#persistent-local-database.

The @seald-io/sdk-plugin-localstorage module allows to store the Seald identity in the browser's localStorage, encrypted by a localStorageKey.

For the localStorageKey, you can either use a user password, or a random string stored by your back-end and given after authentication.

This module exposes a function, that takes prefix as argument, and returns a SDKPlugin which can be passed to the SealdSDK constructor.

When the Seald SDK is passed this plugin, the SealdSDK instance is modified to have a localStorage property, which exposes the PluginLocalStorage interface.

Example:

import SealdSDK from '@seald-io/sdk-web'
import SealdSDKPluginLocalStorage from '@seald-io/sdk-plugin-localstorage'

const seald = SealdSDK({
  appId,
  plugins: [SealdSDKPluginLocalStorage()] // passing the plugin to SealdSDK
})
await seald.initialize()

// Creating a Seald identity
await seald.initiateIdentity({ userId, userLicenseToken })
// The SealdSDK instance now has a `localStorage` property : we can use `saveIdentity`
await seald.localStorage.saveIdentity({ userId, localStorageKey })

For more information, visit our website : https://seald.io

For the full documentation, visit our documentation page : https://docs.seald.io/en/sdk/

© 2021 Seald SAS

0.13.0

4 years ago

0.13.0-beta.1

4 years ago

0.12.0

4 years ago

0.13.0-beta.0

4 years ago

0.11.0

4 years ago

0.11.1

4 years ago

0.10.0-beta.0

4 years ago

0.10.0

4 years ago

0.12.0-beta.0

4 years ago

0.9.0

4 years ago

0.9.0-beta.1

4 years ago

0.9.0-beta.0

4 years ago

0.8.1

4 years ago

0.8.0

4 years ago

0.8.0-beta.1

4 years ago

0.8.0-beta.0

4 years ago

0.7.0

4 years ago

0.7.0-beta.0

4 years ago

0.6.0

4 years ago

0.6.0-alpha.4

4 years ago

0.6.0-alpha.2

4 years ago

0.6.0-alpha.1

4 years ago

0.6.0-alpha.0

4 years ago

0.5.3-alpha.0

4 years ago

0.5.2

4 years ago

0.5.1-alpha.5

4 years ago

0.5.1

4 years ago

0.5.0

4 years ago

0.4.1-alpha.2

4 years ago

0.4.1-alpha.1

4 years ago

0.4.1-alpha.0

4 years ago