Cargo.toml 16 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557
  1. [workspace]
  2. resolver = "2"
  3. members = [
  4. "packages/dioxus",
  5. "packages/dioxus-lib",
  6. "packages/core",
  7. "packages/core-types",
  8. "packages/cli",
  9. "packages/cli-opt",
  10. "packages/core-types",
  11. "packages/core-macro",
  12. "packages/config-macro",
  13. "packages/router-macro",
  14. "packages/extension",
  15. "packages/router",
  16. "packages/html",
  17. "packages/html-internal-macro",
  18. "packages/hooks",
  19. "packages/web",
  20. "packages/ssr",
  21. "packages/desktop",
  22. "packages/mobile",
  23. "packages/interpreter",
  24. "packages/liveview",
  25. "packages/autofmt",
  26. "packages/check",
  27. "packages/cli-config",
  28. "packages/cli",
  29. "packages/config-macro",
  30. "packages/core-macro",
  31. "packages/core-types",
  32. "packages/core",
  33. "packages/desktop",
  34. "packages/devtools-types",
  35. "packages/devtools",
  36. "packages/dioxus-lib",
  37. "packages/dioxus",
  38. "packages/document",
  39. "packages/extension",
  40. "packages/fullstack",
  41. "packages/fullstack-hooks",
  42. "packages/fullstack-protocol",
  43. "packages/generational-box",
  44. "packages/history",
  45. "packages/hooks",
  46. "packages/html-internal-macro",
  47. "packages/html",
  48. "packages/interpreter",
  49. "packages/lazy-js-bundle",
  50. "packages/liveview",
  51. "packages/mobile",
  52. "packages/router-macro",
  53. "packages/router",
  54. "packages/rsx-hotreload",
  55. "packages/rsx-rosetta",
  56. "packages/rsx",
  57. "packages/server-macro",
  58. "packages/signals",
  59. "packages/ssr",
  60. "packages/lazy-js-bundle",
  61. "packages/cli-config",
  62. "packages/devtools",
  63. "packages/devtools-types",
  64. "packages/isrg",
  65. "packages/rsx-hotreload",
  66. "packages/const-serialize",
  67. "packages/const-serialize-macro",
  68. "packages/dx-wire-format",
  69. "packages/logger",
  70. "packages/config-macros",
  71. "packages/native",
  72. "packages/asset-resolver",
  73. # Playwright tests
  74. "packages/playwright-tests/liveview",
  75. "packages/playwright-tests/web",
  76. "packages/playwright-tests/fullstack",
  77. "packages/playwright-tests/suspense-carousel",
  78. "packages/playwright-tests/nested-suspense",
  79. # manganis
  80. "packages/manganis/manganis",
  81. "packages/manganis/manganis-core",
  82. "packages/manganis/manganis-macro",
  83. # wasm-split
  84. "packages/wasm-split/wasm-split",
  85. "packages/wasm-split/wasm-split-macro",
  86. "packages/wasm-split/wasm-split-cli",
  87. "packages/wasm-split/wasm-used",
  88. # Full project examples
  89. "example-projects/fullstack-hackernews",
  90. "example-projects/ecommerce-site",
  91. "example-projects/wifi-scanner",
  92. "example-projects/file-explorer",
  93. # Simple examples that require a crate
  94. "examples/tailwind",
  95. "examples/pwa",
  96. "examples/fullstack-hello-world",
  97. "examples/fullstack-router",
  98. "examples/fullstack-streaming",
  99. "examples/fullstack-desktop",
  100. "examples/fullstack-auth",
  101. # Playwright tests
  102. "packages/playwright-tests/liveview",
  103. "packages/playwright-tests/web",
  104. "packages/playwright-tests/fullstack",
  105. "packages/playwright-tests/fullstack-mounted",
  106. "packages/playwright-tests/fullstack-routing",
  107. "packages/playwright-tests/suspense-carousel",
  108. "packages/playwright-tests/nested-suspense",
  109. "packages/playwright-tests/cli-optimization",
  110. "packages/playwright-tests/wasm-split-harness",
  111. "packages/playwright-tests/wasm-split-harness",
  112. "packages/playwright-tests/default-features-disabled"
  113. ]
  114. [workspace.package]
  115. version = "0.6.3"
  116. # dependencies that are shared across packages
  117. [workspace.dependencies]
  118. dioxus = { path = "packages/dioxus", version = "0.6.2" }
  119. dioxus-lib = { path = "packages/dioxus-lib", version = "0.6.2" }
  120. dioxus-core = { path = "packages/core", version = "0.6.2" }
  121. dioxus-core-types = { path = "packages/core-types", version = "0.6.2" }
  122. dioxus-core-macro = { path = "packages/core-macro", version = "0.6.2" }
  123. dioxus-config-macro = { path = "packages/config-macro", version = "0.6.2" }
  124. dioxus-router = { path = "packages/router", version = "0.6.2" }
  125. dioxus-router-macro = { path = "packages/router-macro", version = "0.6.2" }
  126. dioxus-document = { path = "packages/document", version = "0.6.2", default-features = false }
  127. dioxus-history = { path = "packages/history", version = "0.6.2", default-features = false }
  128. dioxus-html = { path = "packages/html", version = "0.6.2", default-features = false }
  129. dioxus-html-internal-macro = { path = "packages/html-internal-macro", version = "0.6.2" }
  130. dioxus-hooks = { path = "packages/hooks", version = "0.6.2" }
  131. dioxus-web = { path = "packages/web", version = "0.6.2", default-features = false }
  132. dioxus-isrg = { path = "packages/isrg", version = "0.6.2" }
  133. dioxus-ssr = { path = "packages/ssr", version = "0.6.2", default-features = false }
  134. dioxus-desktop = { path = "packages/desktop", version = "0.6.2", default-features = false }
  135. dioxus-mobile = { path = "packages/mobile", version = "0.6.2" }
  136. dioxus-interpreter-js = { path = "packages/interpreter", version = "0.6.2" }
  137. dioxus-liveview = { path = "packages/liveview", version = "0.6.2" }
  138. dioxus-autofmt = { path = "packages/autofmt", version = "0.6.2" }
  139. dioxus-check = { path = "packages/check", version = "0.6.2" }
  140. dioxus-rsx = { path = "packages/rsx", version = "0.6.2" }
  141. dioxus-rsx-hotreload = { path = "packages/rsx-hotreload", version = "0.6.2" }
  142. dioxus-rsx-rosetta = { path = "packages/rsx-rosetta", version = "0.6.2" }
  143. dioxus-signals = { path = "packages/signals", version = "0.6.2" }
  144. dioxus-cli-config = { path = "packages/cli-config", version = "0.6.2" }
  145. dioxus-cli-opt = { path = "packages/cli-opt", version = "0.6.2" }
  146. dioxus-devtools = { path = "packages/devtools", version = "0.6.2" }
  147. dioxus-devtools-types = { path = "packages/devtools-types", version = "0.6.2" }
  148. dioxus-fullstack = { path = "packages/fullstack", version = "0.6.2" }
  149. dioxus-fullstack-hooks = { path = "packages/fullstack-hooks", version = "0.6.3" }
  150. dioxus-fullstack-protocol = { path = "packages/fullstack-protocol", version = "0.6.3" }
  151. dioxus_server_macro = { path = "packages/server-macro", version = "0.6.2", default-features = false }
  152. dioxus-dx-wire-format = { path = "packages/dx-wire-format", version = "0.6.2" }
  153. dioxus-logger = { path = "packages/logger", version = "0.6.2" }
  154. dioxus-native = { path = "packages/native", version = "0.6.2" }
  155. dioxus-asset-resolver = { path = "packages/asset-resolver", version = "0.6.2" }
  156. dioxus-config-macros = { path = "packages/config-macros", version = "0.6.3" }
  157. const-serialize = { path = "packages/const-serialize", version = "0.6.2" }
  158. const-serialize-macro = { path = "packages/const-serialize-macro", version = "0.6.2" }
  159. generational-box = { path = "packages/generational-box", version = "0.6.2" }
  160. lazy-js-bundle = { path = "packages/lazy-js-bundle", version = "0.6.2" }
  161. manganis = { path = "packages/manganis/manganis", version = "0.6.2" }
  162. manganis-core = { path = "packages/manganis/manganis-core", version = "0.6.2" }
  163. manganis-macro = { path = "packages/manganis/manganis-macro", version = "0.6.2" }
  164. wasm-split = { path = "packages/wasm-split/wasm-split", version = "0.1.0" }
  165. wasm-split-macro = { path = "packages/wasm-split/wasm-split-macro", version = "0.1.0" }
  166. wasm-split-cli = { path = "packages/wasm-split/wasm-split-cli", version = "0.1.0" }
  167. wasm-split-harness = { path = "packages/playwright-tests/wasm-split-harness", version = "0.1.0" }
  168. warnings = { version = "0.2.1" }
  169. # a fork of pretty please for tests - let's get off of this if we can!
  170. prettier-please = { version = "0.3.0", features = ["verbatim"]}
  171. anyhow = "1.0.95"
  172. clap = { version = "4.5.7" }
  173. askama_escape = "0.10.3"
  174. tracing = "0.1.37"
  175. tracing-futures = "0.2.5"
  176. tracing-subscriber = { version = "0.3.18", default-features = false }
  177. toml = "0.8"
  178. tokio = "1.40"
  179. slab = "0.4.2"
  180. slotmap = { version = "1.0.7", features = ["serde"] }
  181. futures = "0.3.31"
  182. futures-channel = "0.3.31"
  183. futures-util = { version = "0.3", default-features = false }
  184. rustc-hash = "1.1.0"
  185. wasm-bindgen = "0.2.99"
  186. wasm-bindgen-futures = "0.4.42"
  187. js-sys = "0.3.76"
  188. web-sys = { version = "0.3.76", default-features = false }
  189. html_parser = "0.7.0"
  190. thiserror = "1.0.40"
  191. prettyplease = { version = "0.2.20", features = ["verbatim"] }
  192. const_format = "0.2.32"
  193. cargo_toml = { version = "0.20.3" }
  194. tauri-utils = { version = "=2.1.1" }
  195. tauri-bundler = { version = "=2.2.3" }
  196. lru = "0.12.2"
  197. async-trait = "0.1.77"
  198. axum = "0.8.1"
  199. axum-server = { version = "0.7.1", default-features = false }
  200. tower = "0.4.13"
  201. http = "1.0.0"
  202. notify = { version = "6.1.1" }
  203. tower-http = "0.5.2"
  204. hyper = "1.0.0"
  205. hyper-rustls = { version= "0.27.2", default-features = false , features=["native-tokio","http1","http2","tls12","logging","ring"]}
  206. rustls = { version="0.23.12", default-features=false, features =["logging","std","tls12","ring"] }
  207. serde_json = "1.0.61"
  208. serde = "1.0.61"
  209. syn = "2.0"
  210. quote = "1.0"
  211. proc-macro2 = "1.0"
  212. axum_session = "0.16.0"
  213. axum_session_auth = "0.16.0"
  214. axum_session_sqlx = "0.5.0"
  215. axum-extra = "0.9.2"
  216. reqwest = "0.12.5"
  217. owo-colors = "4.0.0"
  218. ciborium = "0.2.1"
  219. base64 = "0.22.1"
  220. once_cell = "1.17.1"
  221. uuid = "1.9.1"
  222. convert_case = "0.6.0"
  223. tokio-tungstenite = { version = "0.23.1" }
  224. gloo-timers = "0.3.0"
  225. fluent-uri = { version = "0.2.0", features = ["serde"] }
  226. internment = { version = "0.7.0" }
  227. proc-macro2-diagnostics = { version = "0.10", default-features = false }
  228. env_logger = "0.11.0"
  229. chrono = { version = "0.4.34" }
  230. gloo = { version = "0.8.0" }
  231. gloo-utils = { version = "0.1.6" }
  232. rustversion = "1.0.17"
  233. rand = "0.8.5"
  234. longest-increasing-subsequence = "0.1.0"
  235. trybuild = "1.0"
  236. dirs = "5.0.1"
  237. cargo-config2 = "0.1.26"
  238. criterion = { version = "0.5" }
  239. cargo_metadata = "0.18.1"
  240. parking_lot = "0.12.1"
  241. tracing-wasm = "0.2.1"
  242. console_error_panic_hook = "0.1.7"
  243. base16 = "0.2.1"
  244. digest = "0.10.7"
  245. sha2 = "0.10.8"
  246. walrus = { version = "0.23.2", features = ["parallel"] }
  247. id-arena = "2.2.1"
  248. async-compression = { version = "0.4.8", features = ["futures-io", "gzip", "brotli"] }
  249. getrandom = { version = "0.2" }
  250. async-once-cell = { version = "0.5.3" }
  251. rayon = "1.2.0"
  252. wasmparser = "0.225.0"
  253. itertools = "0.14.0"
  254. macro-string = "0.1.3"
  255. walkdir = "2.5.0"
  256. url = "2.3.1"
  257. # desktop
  258. wry = { version = "0.50.1", default-features = false }
  259. tao = { version = "0.30.8", features = ["rwh_05"] }
  260. webbrowser = "1.0.1"
  261. infer = "0.16.0"
  262. dunce = "1.0.5"
  263. urlencoding = "2.1.2"
  264. global-hotkey = "0.6.0"
  265. rfd = { version = "0.14", default-features = false }
  266. muda = "0.15.3"
  267. cocoa = "0.26"
  268. core-foundation = "0.10.0"
  269. objc = { version = "0.2.7", features = ["exception"] }
  270. objc_id = "0.1.1"
  271. tray-icon = "0.19"
  272. # native
  273. keyboard-types = "0.7"
  274. winit = { version = "0.30.2", features = ["rwh_06"] }
  275. # disable debug symbols in dev builds - shouldn't matter for downstream crates but makes our binaries (examples, cli, etc) build faster
  276. [profile.dev]
  277. debug = 0
  278. # our release profile should be fast to compile and fast to run
  279. # when we ship our CI builds, we turn on LTO which improves perf leftover by turning on incremental
  280. [profile.release]
  281. incremental = true
  282. # crank up the opt level for wasm-split-cli in dev mode
  283. # important here that lto is on and the debug symbols are presenta (since they're used by wasm-opt)a
  284. [profile.wasm-split-release]
  285. inherits = "release"
  286. opt-level = 'z'
  287. lto = true
  288. debug=true
  289. # a profile for running the CLI that's also incremental
  290. [profile.cli-release-dev]
  291. inherits = "release"
  292. opt-level = 3
  293. incremental = true
  294. # crank up walrus since it's quite slow in dev mode
  295. [profile.dev.package.walrus]
  296. opt-level = 3
  297. [profile.release-max-opt]
  298. inherits = "release"
  299. lto = true
  300. codegen-units = 1
  301. # Disable debug assertions to check the released path of core and other packages, but build without optimizations to keep build times quick
  302. [profile.release-unoptimized]
  303. inherits = "dev"
  304. debug-assertions = false
  305. incremental = true
  306. [profile.wasm-dev]
  307. inherits = "dev"
  308. opt-level = 1
  309. [profile.server-dev]
  310. inherits = "dev"
  311. [profile.android-dev]
  312. inherits = "dev"
  313. # This is a "virtual package"
  314. # It is not meant to be published, but is used so "cargo run --example XYZ" works properly
  315. [package]
  316. name = "dioxus-examples"
  317. authors = ["Jonathan Kelley"]
  318. edition = "2021"
  319. description = "Top level crate for the Dioxus repository"
  320. license = "MIT OR Apache-2.0"
  321. repository = "https://github.com/DioxusLabs/dioxus/"
  322. homepage = "https://dioxuslabs.com"
  323. documentation = "https://dioxuslabs.com"
  324. keywords = ["dom", "ui", "gui", "react", "wasm"]
  325. rust-version = "1.79.0"
  326. publish = false
  327. version = "0.6.3"
  328. [dependencies]
  329. reqwest = { workspace = true, features = ["json"], optional = true }
  330. ciborium = { workspace = true, optional = true }
  331. base64 = { workspace = true, optional = true }
  332. http-range = { version = "0.1.5", optional = true }
  333. wgpu = { version = "0.19", optional = true }
  334. ouroboros = { version = "*", optional = true }
  335. wasm-split = { workspace = true }
  336. [dev-dependencies]
  337. dioxus = { workspace = true, features = ["router"] }
  338. dioxus-ssr = { workspace = true }
  339. futures-util = "0.3.31"
  340. separator = "0.4.1"
  341. serde = { version = "1.0.136", features = ["derive"] }
  342. serde_json = "1.0.79"
  343. rand = { version = "0.8.4", features = ["small_rng"] }
  344. form_urlencoded = "1.2.0"
  345. async-std = "1.12.0"
  346. web-time = "1.1.0"
  347. axum = { workspace = true, default-features = true }
  348. [target.'cfg(target_arch = "wasm32")'.dev-dependencies]
  349. getrandom = { version = "0.2.12", features = ["js"] }
  350. tokio = { version = "1.40", default-features = false, features = [
  351. "sync",
  352. "macros",
  353. "io-util",
  354. "rt",
  355. "time"
  356. ] }
  357. [target.'cfg(not(target_arch = "wasm32"))'.dev-dependencies]
  358. tokio = { version = "1.40", features = ["full"] }
  359. # force vendored openssl on android
  360. [target.'cfg(target_os = "android")'.dev-dependencies]
  361. openssl = { version = "0.10", features = ["vendored"] }
  362. # To make most examples faster to compile, we split out assets and http-related stuff
  363. # This trims off like 270 dependencies, leading to a significant speedup in compilation time
  364. [features]
  365. default = ["desktop"]
  366. desktop = ["dioxus/desktop"]
  367. liveview = ["dioxus/liveview"]
  368. fullstack = ["dioxus/fullstack"]
  369. server = ["dioxus/server"]
  370. mobile = ["dioxus/mobile"]
  371. web = ["dioxus/web"]
  372. http = ["dep:reqwest", "dep:http-range"]
  373. gpu = ["dep:ouroboros", "dep:wgpu"]
  374. [[example]]
  375. name = "login_form"
  376. required-features = ["http"]
  377. doc-scrape-examples = true
  378. [[example]]
  379. name = "dog_app"
  380. required-features = ["http"]
  381. doc-scrape-examples = true
  382. [[example]]
  383. name = "video_stream"
  384. required-features = ["http", "desktop"]
  385. doc-scrape-examples = true
  386. [[example]]
  387. name = "suspense"
  388. required-features = ["http", "desktop"]
  389. doc-scrape-examples = true
  390. [[example]]
  391. name = "weather_app"
  392. required-features = ["http"]
  393. doc-scrape-examples = true
  394. [[example]]
  395. name = "image_generator_openai"
  396. required-features = ["http"]
  397. doc-scrape-examples = true
  398. [[example]]
  399. name = "hash_fragment_state"
  400. required-features = ["ciborium", "base64"]
  401. doc-scrape-examples = true
  402. [[example]]
  403. name = "backgrounded_futures"
  404. required-features = ["desktop"]
  405. doc-scrape-examples = true
  406. [[example]]
  407. name = "calculator_mutable"
  408. required-features = ["desktop"]
  409. doc-scrape-examples = true
  410. [[example]]
  411. name = "calculator"
  412. required-features = ["desktop"]
  413. doc-scrape-examples = true
  414. [[example]]
  415. name = "clock"
  416. doc-scrape-examples = true
  417. [[example]]
  418. name = "crm"
  419. required-features = ["desktop"]
  420. doc-scrape-examples = true
  421. [[example]]
  422. name = "custom_html"
  423. required-features = ["desktop"]
  424. doc-scrape-examples = true
  425. [[example]]
  426. name = "custom_menu"
  427. required-features = ["desktop"]
  428. doc-scrape-examples = true
  429. [[example]]
  430. name = "dynamic_asset"
  431. required-features = ["desktop"]
  432. doc-scrape-examples = true
  433. [[example]]
  434. name = "errors"
  435. required-features = ["desktop"]
  436. doc-scrape-examples = true
  437. [[example]]
  438. name = "future"
  439. doc-scrape-examples = true
  440. [[example]]
  441. name = "hydration"
  442. required-features = ["desktop"]
  443. doc-scrape-examples = true
  444. [[example]]
  445. name = "multiwindow"
  446. required-features = ["desktop"]
  447. doc-scrape-examples = true
  448. [[example]]
  449. name = "overlay"
  450. required-features = ["desktop"]
  451. doc-scrape-examples = true
  452. [[example]]
  453. name = "popup"
  454. required-features = ["desktop"]
  455. doc-scrape-examples = true
  456. [[example]]
  457. name = "read_size"
  458. required-features = ["desktop"]
  459. doc-scrape-examples = true
  460. [[example]]
  461. name = "shortcut"
  462. required-features = ["desktop"]
  463. doc-scrape-examples = true
  464. [[example]]
  465. name = "streams"
  466. doc-scrape-examples = true
  467. [[example]]
  468. name = "visible"
  469. doc-scrape-examples = true
  470. [[example]]
  471. name = "window_event"
  472. required-features = ["desktop"]
  473. doc-scrape-examples = true
  474. [[example]]
  475. name = "window_focus"
  476. required-features = ["desktop"]
  477. doc-scrape-examples = true
  478. [[example]]
  479. name = "window_zoom"
  480. required-features = ["desktop"]
  481. doc-scrape-examples = true
  482. [[example]]
  483. name = "wgpu_child_window"
  484. required-features = ["desktop", "gpu"]
  485. [[example]]
  486. name = "control_focus"
  487. doc-scrape-examples = true
  488. [[example]]
  489. name = "eval"
  490. doc-scrape-examples = true
  491. [[example]]
  492. name = "logging"
  493. doc-scrape-examples = true