This commit is contained in:
2025-02-22 09:52:00 -03:00
parent 7b51166db8
commit bc77e892a5
11 changed files with 375 additions and 32 deletions

View File

@@ -0,0 +1,13 @@
import { encodeURI, decode } from 'js-base64'
export function encode(data) {
return encodeURI(JSON.stringify(data))
}
export function parse(str) {
try {
return JSON.parse(decode(str))
} catch {
return null
}
}