forked from martinkasa/capacitor-secure-storage-plugin
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Showing
68 changed files
with
4,563 additions
and
3,404 deletions.
There are no files selected for viewing
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4,12 +4,18 @@ Capacitor plugin for storing string values securly on iOS and Android. | |
|
||
## How to install | ||
|
||
For Capacitor v4 | ||
For Capacitor v5 | ||
|
||
```bash | ||
npm install capacitor-secure-storage-plugin | ||
``` | ||
|
||
For Capacitor v4 - install with fixed version 0.8.1 | ||
|
||
```bash | ||
npm install [email protected] | ||
``` | ||
|
||
For Capacitor v3 - install with fixed version 0.7.1 | ||
|
||
```bash | ||
|
@@ -73,38 +79,38 @@ public class MainActivity extends BridgeActivity { | |
## Methods | ||
```ts | ||
```ts | ||
|
||
get(options: { key: string }): Promise<{ value: string }> | ||
get(options: { key: string }): Promise<{ value: string }> | ||
|
||
``` | ||
``` | ||
> **Note** | ||
> if item with specified key does not exist, throws an Error | ||
> **Note** | ||
> if item with specified key does not exist, throws an Error | ||
--- | ||
--- | ||
```ts | ||
```ts | ||
|
||
set(options: { key: string; value: string }): Promise<{ value: boolean }> | ||
set(options: { key: string; value: string }): Promise<{ value: boolean }> | ||
|
||
``` | ||
``` | ||
> **Note** | ||
> return true in case of success otherwise throws an error | ||
> **Note** | ||
> return true in case of success otherwise throws an error | ||
--- | ||
--- | ||
```ts | ||
```ts | ||
|
||
remove(options: { key: string }): Promise<{ value: boolean }> | ||
remove(options: { key: string }): Promise<{ value: boolean }> | ||
|
||
``` | ||
``` | ||
> **Note** | ||
> return true in case of success otherwise throws an error | ||
> **Note** | ||
> return true in case of success otherwise throws an error | ||
--- | ||
--- | ||
```ts | ||
keys(): Promise<{ value: string[] }> | ||
|
@@ -116,30 +122,29 @@ keys(): Promise<{ value: string[] }> | |
|
||
clear(): Promise<{ value: boolean }> | ||
|
||
``` | ||
``` | ||
> **Note** | ||
> return true in case of success otherwise throws an error | ||
> **Note** | ||
> return true in case of success otherwise throws an error | ||
--- | ||
--- | ||
```ts | ||
```ts | ||
|
||
getPlatform(): Promise<{ value: string }> | ||
getPlatform(): Promise<{ value: string }> | ||
|
||
``` | ||
``` | ||
> **Note** | ||
> return returns which implementation is used - one of 'web', 'ios' or 'android' | ||
> **Note** | ||
> return returns which implementation is used - one of 'web', 'ios' or 'android' | ||
## Example | ||
```ts | ||
const key = 'username'; | ||
const value = 'hellokitty2'; | ||
|
||
SecureStoragePlugin.set({ key, value }) | ||
.then(success => console.log(success)) | ||
SecureStoragePlugin.set({ key, value }).then(success => console.log(success)); | ||
``` | ||
```ts | ||
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file added
BIN
+17 Bytes
android/.gradle/8.0.2/dependencies-accessors/dependencies-accessors.lock
Binary file not shown.
Empty file.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Empty file.
Binary file not shown.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,2 @@ | ||
#Thu Jul 28 18:18:21 CEST 2022 | ||
gradle.version=7.4.2 | ||
#Thu May 18 07:28:54 CEST 2023 | ||
gradle.version=8.0.2 |
Binary file not shown.
Binary file not shown.
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
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
Binary file not shown.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,6 @@ | ||
distributionBase=GRADLE_USER_HOME | ||
distributionPath=wrapper/dists | ||
distributionUrl=https://services.gradle.org/distributions/gradle-7.4.2-bin.zip | ||
distributionUrl=https\://services.gradle.org/distributions/gradle-8.0.2-all.zip | ||
networkTimeout=10000 | ||
zipStoreBase=GRADLE_USER_HOME | ||
zipStorePath=wrapper/dists |
Oops, something went wrong.