Your Thoughts on Tauri for Deployed Projects

Good morning!

Goal: to see if Tauri is a viable deployment option for RPG MV/MZ and if there are things in place for compiling js to bytecode for source code protection, asset protection, and maintain the concept of "cross-platform" as well as "no-bloat" with little to no performance drops/errors.


TL;DR: I deployed a prototype MV game with Tauri for testing on Windows. It works, no bloat, no performance drop, and single .msi/exe file (original project: 256MB; .msi: 245MB; standalone app: 253MB.
Thoughts on performance on other computers and asset protection (compiling js to bytecode and protecting assets - is it possible under Tauri)?

-----

After a few tests, I have deployed a quick prototype MV game on my Win 11 computer using Tauri instead of NWJS with what seems like initial success. No errors, slow load times, or frame drops. The size of the app is pretty much the same size as the original (pre-deployment) folder - from a 256MB project, Tauri created 245MB for the msi file, 253MB for the standalone app, making it a single-executable that contains all the assets which is quite convenient.

The questions are:

- When tauri compiles this app, it says that it compiles the code - does this only pertain to the Rust code or the entire project?

- Are the js files also "compiled" or is there a way to convert them to bytecode (via bytenode, etc.) and still have them work properly since bytecode is specific to the browser/version? (nwjc is what nwjs uses to compile and run the js bytecode)

- Are other assets (images/audio/etc) protected or will I need to find another way to protect them?

- Since Tauri uses WebView2, would the application be at the mercy of each machine (which, may not be a problem if I am only making it available for Win 10+ computers) - is requiring the OS to be 10 or higher enough for system/app requirements in terms of software?

- In my first few attempts, I was able to compile the js files to bytecode using bytenode and added it as a dependency to the project but was unsuccessful in getting the app to read the compile code properly. Anyone have a lead on this part in terms of the tauri environment?
My assumption is that it would be similar to how nwjc works and I just need to change a few lines of code and find a way for it to use the dependency. I know the index.html needs an eval bin script/src but I am also thinking that it didn't find the dependency/compiler (which would have been the nwjc in nwjs) - will look into a few options and report back.

Of course, as with anything, it is only a matter of spending time and effort for someone to hack and get what they want out of software - these questions are simply to make sure I am doing my own due diligence.

Tauri's statement on security suggests that even though it is compiled and will take effort to reverse engineer things, efforts to protect assets can also be implemented as another layer.

it seems that obfuscation is to be avoided in case of performance issues so that would not be a current, viable option. With a projected deployed with NWJS, I have been able to compile js to bytecode and run with almost no issues (exceptions were from certain eval/jsonparse type scripts that did not work properly).

Your thoughts and input are greatly appreciated.

Original thread: https://forums.rpgmakerweb.com/threads/your-thoughts-on-tauri-for-deployed-projects.168534/