DiscordTauri/discord-tauri

Decompressing asar ?

snowc0de opened this issue · 3 comments

All the data on the normal Discord is stored in the app.asar file that can be decompressed using the command asar e app.asar out

It could also be possible to use the OpenAsar implementation of it which is ridiculously small however I don't know how it really works.

Generally speaking we can't just extract the thing because everything is in Javascript and uses the Electron API but it's just an idea, and maybe something could be done with that, it would avoid having to fetch all the assets and others from the website since everything would be bundled inside the binary.

I hace thought about this, we would need to fork OpenAsar to replace the Electron API

Yes but I'm suspicious of OpenAsar, the size is really suspiciously small, and the extracted content itself doesn't contain any asset (image, video, or anything). Just a few JS files. So I suspect it just fetches everything from the web version.

Meanwhile the original Discord app.asar has all the assets and stuff included.

This is actually quite a good idea, although might take a while to remake the scripts. But this will allow for a much more native-like experience