From cb5eaab30b5b42f4d7f8b95ccec288d0ec432180 Mon Sep 17 00:00:00 2001 From: Kareem Mahlees Date: Fri, 29 Dec 2023 18:35:57 +0200 Subject: [PATCH] refactor: some tricks to reduce bundle size --- src-tauri/Cargo.toml | 7 +++++++ tsconfig.json | 1 + 2 files changed, 8 insertions(+) diff --git a/src-tauri/Cargo.toml b/src-tauri/Cargo.toml index 6960e753..84d31aec 100644 --- a/src-tauri/Cargo.toml +++ b/src-tauri/Cargo.toml @@ -9,6 +9,13 @@ default-run = "table_x" edition = "2021" rust-version = "1.60" +[profile.release] +panic = "abort" +codegen-units = 1 +lto = true +opt-level = "s" +strip = true + # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html [build-dependencies] diff --git a/tsconfig.json b/tsconfig.json index e59724b2..ea862760 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -13,6 +13,7 @@ "isolatedModules": true, "jsx": "preserve", "incremental": true, + "sourceMap": false, "plugins": [ { "name": "next"