tauri/core/tauri-utils
Lucas Fernandes Nogueira d0510f52eb
refactor(core): serialize response once, closes #5641 (#10641)
* refactor(core): serialize response once closes #5641

This change impacts both the custom protocol and the postMessage based IPC implementations. Basically it changes the whole IPC mechanism to work on raw JSON strings so we do not need to serialize a serde_json::Value after serializing to it from a user-provided type.

i benchmarked this with a 150MB file response (returning Vec<u8> instead of tauri::ipc::Response since the latter does not serialize at all) and it went from 29s to 23s (custom protocol) and from 54s to 48s (post message) on macOS.

* fix mobile & lint

* clippy
2024-08-15 16:15:11 -03:00
..
src refactor(core): serialize response once, closes #5641 (#10641) 2024-08-15 16:15:11 -03:00
Cargo.toml chore: update brotli dependency to v6 (#10436) 2024-08-11 08:23:31 -03:00
CHANGELOG.md apply version updates (#10532) 2024-08-08 23:52:47 -03:00
LICENSE_APACHE-2.0 fix: prune packages, add license files, closes #1507 (#1769) 2021-05-10 20:28:15 -03:00
LICENSE_MIT fix: prune packages, add license files, closes #1507 (#1769) 2021-05-10 20:28:15 -03:00
README.md Merge remote-tracking branch 'origin/dev' into next (#7067) 2023-05-29 21:29:24 -03:00

tauri-utils

status License test core FOSSA Status Chat Server website https://good-labs.github.io/greater-good-affirmation/assets/images/badge.svg support

Component Version
tauri-utils

About Tauri

Tauri is a polyglot and generic system that is very composable and allows engineers to make a wide variety of applications. It is used for building applications for Desktop Computers using a combination of Rust tools and HTML rendered in a Webview. Apps built with Tauri can ship with any number of pieces of an optional JS API / Rust API so that webviews can control the system via message passing. In fact, developers can extend the default API with their own functionality and bridge the Webview and Rust-based backend easily.

Tauri apps can have custom menus and have tray-type interfaces. They can be updated, and are managed by the user's operating system as expected. They are very small, because they use the system's webview. They do not ship a runtime, since the final binary is compiled from rust. This makes the reversing of Tauri apps not a trivial task.

This module

This is common code that is reused in many places and offers useful utilities like parsing configuration files, detecting platform triples, injecting the CSP, and managing assets.

To learn more about the details of how all of these pieces fit together, please consult this ARCHITECTURE.md document.

Semver

tauri is following Semantic Versioning 2.0.

Licenses

Code: (c) 2021 - The Tauri Programme within The Commons Conservancy.

MIT or MIT/Apache 2.0 where applicable.

Logo: CC-BY-NC-ND