-
Notifications
You must be signed in to change notification settings - Fork 90
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: add support for brotli compression (#300)
* feat(compression): Generate perseus engine brotli compressed files. Change the servers configuration to look for the .br files first and if not found defaults to the uncompressed file. Changed the servers(actix-web, axum, rocket, warp) configuration to add a dflt-server-with-compression feature that enables native server compression. By default, brotli compress the perseus_engine.js, perseus_engine.wasm, perseus_engine.d.ts and perseus_engine_bg.wasm.d.ts. This behaviour can be deactivated with the disable_engine_compression flag on the perseus CLI. * Update packages/perseus-actix-web/src/lib.rs Co-authored-by: Sam Brew <[email protected]> * Update packages/perseus-actix-web/src/lib.rs Co-authored-by: Sam Brew <[email protected]> * Update packages/perseus-actix-web/src/lib.rs Co-authored-by: Sam Brew <[email protected]> * Update packages/perseus-axum/Cargo.toml Co-authored-by: Sam Brew <[email protected]> * Update packages/perseus-axum/src/lib.rs Co-authored-by: Sam Brew <[email protected]> * Update packages/perseus-cli/src/build.rs Co-authored-by: Sam Brew <[email protected]> * Update packages/perseus-cli/src/build.rs Co-authored-by: Sam Brew <[email protected]> * Update packages/perseus-cli/src/parse.rs Co-authored-by: Sam Brew <[email protected]> * Update packages/perseus-rocket/src/lib.rs Co-authored-by: Sam Brew <[email protected]> * Update packages/perseus-rocket/Cargo.toml Co-authored-by: Sam Brew <[email protected]> * Update packages/perseus-warp/Cargo.toml Co-authored-by: Sam Brew <[email protected]> * Update packages/perseus-warp/src/lib.rs Co-authored-by: Sam Brew <[email protected]> * feat(compression): Simplify rocket integration, change flag name from disable_engine_compression to disable_bundle_compression, compress only for deploy and not on debug build * feat(chore): Resolve conflict on Cargo.toml in perseus-cli * chore: format all with cargo fmt --------- Co-authored-by: Julien Teruel <[email protected]> Co-authored-by: Sam Brew <[email protected]>
- Loading branch information
1 parent
2d2aa14
commit 8016599
Showing
12 changed files
with
254 additions
and
21 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.