2024-12-09 23:04:35 +00:00
|
|
|
export async function deleteItemAsync(key: string): Promise<void> {
|
|
|
|
return localStorage.removeItem(key)
|
|
|
|
}
|
|
|
|
|
2024-12-09 21:57:59 +00:00
|
|
|
export function getItem(key: string): string | null {
|
|
|
|
return localStorage.getItem(key)
|
|
|
|
}
|
|
|
|
|
|
|
|
export async function getItemAsync(key: string): Promise<string | null> {
|
|
|
|
return localStorage.getItem(key)
|
|
|
|
}
|
|
|
|
|
|
|
|
export function setItem(key: string, value: string): void {
|
|
|
|
localStorage.setItem(key, value)
|
|
|
|
}
|
|
|
|
|
|
|
|
export async function setItemAsync(key: string, value: string): Promise<void> {
|
|
|
|
localStorage.setItem(key, value)
|
|
|
|
}
|