ApiSessionFunctions
Function: grantStore()
function grantStore(storage?, key?): object;Defined in: packages/core/src/session/connect.ts:710
Where an app keeps its grants between visits: one per account, each made out to a key of its own, so two accounts never show peers one key.
Parameters
| Parameter | Type | Default value |
|---|---|---|
storage? | KeyValueStore | null | ... |
key? | string | 'minca.grants' |
Returns
forget
forget: (did) => void;Parameters
| Parameter | Type |
|---|---|
did | string |
Returns
void
get
get: (did) => KeptGrant | null;Parameters
| Parameter | Type |
|---|---|
did | string |
Returns
KeptGrant | null
list
list: () => readonly KeptGrant[] = all;Every account, the one connected first first; an expired grant stays, to show and renew
Returns
readonly KeptGrant[]
save()
save(grant, keyName): void;Parameters
| Parameter | Type |
|---|---|
grant | Grant |
keyName | string |
Returns
void