2024-10-12 14:35:58 +08:00
|
|
|
import { useStarCloudStore } from '@/starCloud/starCloud'
|
|
|
|
|
|
|
|
|
|
export function setStorage(key, value) {
|
|
|
|
|
return uni.setStorageSync(getPrefix() + key, value)
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
export function getStorage(key) {
|
|
|
|
|
return uni.getStorageSync(getPrefix() + key)
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
export function removeStorage(key) {
|
|
|
|
|
return uni.removeStorageSync(getPrefix() + key)
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
function getPrefix() {
|
|
|
|
|
const starCloud = useStarCloudStore()
|
2024-10-21 09:58:17 +08:00
|
|
|
return `${starCloud.envVersion}:`
|
2024-10-12 14:35:58 +08:00
|
|
|
}
|