mirror of
https://github.com/misode/misode.github.io.git
synced 2026-04-25 16:16:50 +00:00
Skip encoding/decoding step when importing and downloading projects
This commit is contained in:
@@ -47,8 +47,7 @@ export function ProjectPanel() {
|
||||
if (!download.current || entries === undefined) return
|
||||
const zipEntries = await Promise.all(entries.map(async e => {
|
||||
const data = await client.fs.readFile(projectRoot + e)
|
||||
const text = new TextDecoder().decode(data)
|
||||
return [e, text] as [string, string]
|
||||
return [e, data] as [string, Uint8Array]
|
||||
}))
|
||||
const url = await writeZip(zipEntries)
|
||||
download.current.setAttribute('href', url)
|
||||
|
||||
Reference in New Issue
Block a user