mirror of
https://github.com/zhigang1992/reactfire.git
synced 2026-05-14 02:24:29 +08:00
update docs script
This commit is contained in:
60
README.md
60
README.md
@@ -13,12 +13,56 @@ or, if you don't want to deal with Suspense, pass an
|
||||
|
||||
## Interfaces
|
||||
|
||||
### AuthCheckProps
|
||||
|
||||
|Property|Type|
|
||||
|---|---|
|
||||
|auth|Auth|
|
||||
|children|React.Component|
|
||||
|fallback|React.Component|
|
||||
|requiredClaims|Object|
|
||||
|
||||
### SuspensePerfProps
|
||||
|
||||
|Property|Type|
|
||||
|---|---|
|
||||
|children|React.Component|
|
||||
|fallback|React.Component|
|
||||
|firePerf|any|
|
||||
|traceId|string|
|
||||
|
||||
### ReactFireOptions
|
||||
|
||||
|Property|Type|
|
||||
|---|---|
|
||||
|startWithValue|any|
|
||||
|
||||
## Components
|
||||
|
||||
### `AuthCheck`
|
||||
|
||||
|
||||
|
||||
#### Props
|
||||
|
||||
interface `AuthCheckProps`
|
||||
|
||||
#### Returns
|
||||
|
||||
React.FunctionComponent
|
||||
|
||||
### `SuspenseWithPerf`
|
||||
|
||||
|
||||
|
||||
#### Props
|
||||
|
||||
interface `SuspensePerfProps`
|
||||
|
||||
#### Returns
|
||||
|
||||
React.FunctionComponent
|
||||
|
||||
## Hooks
|
||||
|
||||
### `useDatabaseList`
|
||||
@@ -127,6 +171,22 @@ Subscribe to Firebase auth state changes, including token refresh
|
||||
|
||||
User
|
||||
|
||||
### `useObservable`
|
||||
|
||||
|
||||
|
||||
#### Parameters
|
||||
|
||||
|Parameter|Type|
|
||||
|---|---|
|
||||
|observable$|Observable|
|
||||
|observableId|string|
|
||||
|startWithValue *?*|any|
|
||||
|
||||
#### Returns
|
||||
|
||||
any
|
||||
|
||||
|
||||
## For development
|
||||
|
||||
|
||||
@@ -6,8 +6,6 @@ import { useObservable } from './util/use-observable';
|
||||
import { getDownloadURL } from 'rxfire/storage';
|
||||
import { Observable, from } from 'rxjs';
|
||||
|
||||
export { SuspenseWithPerf, AuthCheck } from './components';
|
||||
|
||||
export interface ReactFireOptions {
|
||||
startWithValue: any;
|
||||
}
|
||||
@@ -150,3 +148,5 @@ export function useStorageDownloadURL(
|
||||
options ? options.startWithValue : undefined
|
||||
);
|
||||
}
|
||||
|
||||
export { SuspenseWithPerf, AuthCheck } from './components';
|
||||
|
||||
Reference in New Issue
Block a user