原子操作

飞道科技

@dfeidao/atom-mobile > global全局存储

External module: global全局存储

Index

Functions


Functions

get

get<T>(fd: IFeidaoAiMobile, key: string): T

Defined in global/get.ts:18

获取存储

see: api

example:

import get from '@dfeidao/atom-mobile/global/get';
const value = get(fd, 'key');

Type parameters:

T

Parameters:

Name Type Description
fd IFeidaoAiMobile 固定参数
key string

Returns: T


remove

remove(fd: IFeidaoAiMobile, key: string): void

Defined in global/remove.ts:18

移除某个key

see: api

example:

import remove from '@dfeidao/atom-mobile/global/remove';
remove(fd, 'key');

Parameters:

Name Type Description
fd IFeidaoAiMobile 固定参数
key string

Returns: void


set

set(fd: IFeidaoAiMobile, key: string, val: unknown): void

Defined in global/set.ts:19

设置存储

see: api

example:

import set from '@dfeidao/atom-mobile/global/set';
set(fd, 'key', val);

Parameters:

Name Type Description
fd IFeidaoAiMobile 固定参数
key string
val unknown

Returns: void