CLI: add --renderer argument (#4320)

* Add --renderer argument to the CLI

Signed-off-by: Nico Burns <nico@nicoburns.com>

* Make `--platform native` work

Signed-off-by: Nico Burns <nico@nicoburns.com>

* Emit `krates` error when cargo metadata fails

* Reinstate default "desktop" feature for examples

* Remove commented 'no platform specified' error

Signed-off-by: Nico Burns <nico@nicoburns.com>

* use the target tripple and bundle format as the source of truth for the build

* resolve renderer and bundle format

* add shorthand flags

* add headings to the help for shorthands

* resolve the renderer from the target triple if it isn't passed

* make value after --fullstack optional

* convert desktop -> mobile when targeting mobile webview

* use the new shorthand flags in the playwright tests

* fix clippy

* merge fix

* cleanup merge conflicts

* fix clippy

* remove nit

* restore platform as a legacy argument

* improve help message

* vendor openssl on native, pin server_fn

* print build errors as warnings

* add --desktop arg compat

* adjust cli headings

* prefer self.is_wasm_or_wasi()

---------

Signed-off-by: Nico Burns <nico@nicoburns.com>
Co-authored-by: Jonathan Kelley <jkelleyrtp@gmail.com>
Co-authored-by: Evan Almloff <evanalmloff@gmail.com>
This commit is contained in:
authored and GitHub committed 2025-07-22 14:32:54 -07:00
1 parent 4848e714ae
commit b257e7e8ce
28 files changed
+998 -549

No files matched your search

Generated
+11 -11
View File
@@ -5664,6 +5664,7 @@ dependencies = [
"dioxus-native-dom",
"futures-util",
"keyboard-types",
"openssl",
"rustc-hash 2.1.1",
"tokio",
"tracing",
@@ -14276,9 +14277,9 @@ dependencies = [
[[package]]
name = "serde_qs"
version = "0.14.0"
version = "0.15.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "8b417bedc008acbdf6d6b4bc482d29859924114bbe2650b7921fb68a261d0aa6"
checksum = "f3faaf9e727533a19351a43cc5a8de957372163c7d35cc48c90b75cdda13c352"
dependencies = [
"percent-encoding",
"serde",
@@ -14373,9 +14374,9 @@ dependencies = [
[[package]]
name = "server_fn"
version = "0.8.2"
version = "0.8.3"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "09b0f92b9d3a62c73f238ac21f7a09f15bad335a9d1651514d9da80d2eaf8d4c"
checksum = "9c27fbd25ecc066481e383e2ed62ab2480e708aa3fe46cba36e95f58e61dfd04"
dependencies = [
"axum 0.8.4",
"base64 0.22.1",
@@ -14390,7 +14391,6 @@ dependencies = [
"hyper 1.6.0",
"inventory",
"js-sys",
"once_cell",
"pin-project-lite",
"reqwest 0.12.22",
"rustc_version",
@@ -14403,7 +14403,7 @@ dependencies = [
"thiserror 2.0.12",
"throw_error",
"tokio",
"tokio-tungstenite 0.26.2",
"tokio-tungstenite 0.27.0",
"tower 0.5.2",
"tower-layer",
"url",
@@ -14416,9 +14416,9 @@ dependencies = [
[[package]]
name = "server_fn_macro"
version = "0.8.2"
version = "0.8.3"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "341dd1087afe9f3e546c5979a4f0b6d55ac072e1201313f86e7fe364223835ac"
checksum = "b9d530c872590473016016679c94e3bddf47372941fc924f687ffd11a1778a71"
dependencies = [
"const_format",
"convert_case 0.8.0",
@@ -14431,9 +14431,9 @@ dependencies = [
[[package]]
name = "server_fn_macro_default"
version = "0.8.2"
version = "0.8.3"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "bc5ab934f581482a66da82f2b57b15390ad67c9ab85bd9a6c54bb65060fb1380"
checksum = "ca7abc92ed696648275ed9ff171131a83d571af11748593dc2e6eb6a4e22a5b9"
dependencies = [
"server_fn_macro",
"syn 2.0.104",
@@ -16672,7 +16672,6 @@ checksum = "7a9daff607c6d2bf6c16fd681ccb7eecc83e4e2cdc1ca067ffaadfca5de7f084"
dependencies = [
"futures-util",
"log",
"rustls 0.23.29",
"tokio",
"tungstenite 0.26.2",
]
@@ -16685,6 +16684,7 @@ checksum = "489a59b6730eda1b0171fcfda8b121f4bee2b35cba8645ca35c5f7ba3eb736c1"
dependencies = [
"futures-util",
"log",
"rustls 0.23.29",
"tokio",
"tungstenite 0.27.0",
]