stream returns
Some checks failed
Deploy / deploy (push) Has been cancelled

This commit is contained in:
2025-09-24 18:28:42 +08:00
parent 0a9d49b526
commit 0b652aa301
6 changed files with 197 additions and 29 deletions

View File

@@ -183,6 +183,14 @@ export function decode(bytes?: string) {
)
}
export function getCSRFToken() {
if (typeof document === "undefined") {
return ""
}
const match = document.cookie.match(/(?:^|;\s*)csrftoken=([^;]+)/)
return match ? decodeURIComponent(match[1]) : ""
}
// function getChromeVersion() {
// var raw = navigator.userAgent.match(/Chrom(e|ium)\/([0-9]+)\./)
// return raw ? parseInt(raw[2], 10) : 0