mirror of
https://github.com/hanzoai/firebase-js-sdk.git
synced 2026-09-24 16:59:10 +00:00
* Support function links to function overloads. * Improve readability of headings for functions.
90 lines
1.8 KiB
Markdown
90 lines
1.8 KiB
Markdown
Project: /docs/reference/js/_project.yaml
|
|
Book: /docs/reference/_book.yaml
|
|
page_type: reference
|
|
|
|
{% comment %}
|
|
DO NOT EDIT THIS FILE!
|
|
This is generated by the JS SDK team, and any local changes will be
|
|
overwritten. Changes should be made in the source code at
|
|
https://github.com/firebase/firebase-js-sdk
|
|
{% endcomment %}
|
|
|
|
# ReactNativeAsyncStorage interface
|
|
Interface for a supplied `AsyncStorage`<!-- -->.
|
|
|
|
<b>Signature:</b>
|
|
|
|
```typescript
|
|
export interface ReactNativeAsyncStorage
|
|
```
|
|
|
|
## Methods
|
|
|
|
| Method | Description |
|
|
| --- | --- |
|
|
| [getItem(key)](./auth.reactnativeasyncstorage.md#reactnativeasyncstoragegetitem) | Retrieve an item from storage. |
|
|
| [removeItem(key)](./auth.reactnativeasyncstorage.md#reactnativeasyncstorageremoveitem) | Remove an item from storage. |
|
|
| [setItem(key, value)](./auth.reactnativeasyncstorage.md#reactnativeasyncstoragesetitem) | Persist an item in storage. |
|
|
|
|
## ReactNativeAsyncStorage.getItem()
|
|
|
|
Retrieve an item from storage.
|
|
|
|
<b>Signature:</b>
|
|
|
|
```typescript
|
|
getItem(key: string): Promise<string | null>;
|
|
```
|
|
|
|
#### Parameters
|
|
|
|
| Parameter | Type | Description |
|
|
| --- | --- | --- |
|
|
| key | string | storage key. |
|
|
|
|
<b>Returns:</b>
|
|
|
|
Promise<string \| null>
|
|
|
|
## ReactNativeAsyncStorage.removeItem()
|
|
|
|
Remove an item from storage.
|
|
|
|
<b>Signature:</b>
|
|
|
|
```typescript
|
|
removeItem(key: string): Promise<void>;
|
|
```
|
|
|
|
#### Parameters
|
|
|
|
| Parameter | Type | Description |
|
|
| --- | --- | --- |
|
|
| key | string | storage key. |
|
|
|
|
<b>Returns:</b>
|
|
|
|
Promise<void>
|
|
|
|
## ReactNativeAsyncStorage.setItem()
|
|
|
|
Persist an item in storage.
|
|
|
|
<b>Signature:</b>
|
|
|
|
```typescript
|
|
setItem(key: string, value: string): Promise<void>;
|
|
```
|
|
|
|
#### Parameters
|
|
|
|
| Parameter | Type | Description |
|
|
| --- | --- | --- |
|
|
| key | string | storage key. |
|
|
| value | string | storage value. |
|
|
|
|
<b>Returns:</b>
|
|
|
|
Promise<void>
|
|
|