Sen descrición

Jonathan Kelley d160f38bc2 fix: parsing of attributes without trailing commas %!s(int64=2) %!d(string=hai) anos
.docker fc0a093466 try fix %!s(int64=3) %!d(string=hai) anos
.github 937eb1f0f0 Merge pull request #641 from DioxusLabs/dependabot/github_actions/Swatinem/rust-cache-2 %!s(int64=2) %!d(string=hai) anos
.vscode 540e785d8b Less clumsy configuration for desktop and mobile (#553) %!s(int64=2) %!d(string=hai) anos
docs 0bf4725639 fix: namespacing of dynamic attributes %!s(int64=2) %!d(string=hai) anos
examples d160f38bc2 fix: parsing of attributes without trailing commas %!s(int64=2) %!d(string=hai) anos
notes 4eefc3f854 chore: rename all &cx to cx, make clipppy happy %!s(int64=2) %!d(string=hai) anos
packages d160f38bc2 fix: parsing of attributes without trailing commas %!s(int64=2) %!d(string=hai) anos
translations 4eefc3f854 chore: rename all &cx to cx, make clipppy happy %!s(int64=2) %!d(string=hai) anos
.gitignore 8d42191d7a Add `From` trait to convert web_sys Events to html Data %!s(int64=3) %!d(string=hai) anos
CHANGELOG.md 56f3002aed feat: add changelogs %!s(int64=3) %!d(string=hai) anos
Cargo.toml f075a519cc chore: prevent publishing %!s(int64=2) %!d(string=hai) anos
LICENSE-APACHE 6537ad37b8 Add actual copies of the relevant licenses %!s(int64=3) %!d(string=hai) anos
LICENSE-MIT 6537ad37b8 Add actual copies of the relevant licenses %!s(int64=3) %!d(string=hai) anos
Makefile.toml 7fdc72726d Exclude benchmarks from testing (#492) %!s(int64=3) %!d(string=hai) anos
README.md 4eefc3f854 chore: rename all &cx to cx, make clipppy happy %!s(int64=2) %!d(string=hai) anos
codecov.yml e03f8ca90c ci: no more codecov failing %!s(int64=3) %!d(string=hai) anos

README.md


Dioxus is a portable, performant, and ergonomic framework for building cross-platform user interfaces in Rust.

fn app(cx: Scope) -> Element {
    let mut count = use_state(cx, || 0);

    cx.render(rsx! {
        h1 { "High-Five counter: {count}" }
        button { onclick: move |_| count += 1, "Up high!" }
        button { onclick: move |_| count -= 1, "Down low!" }
    })
}

Dioxus can be used to deliver webapps, desktop apps, static sites, mobile apps, TUI apps, liveview apps, and more. Dioxus is entirely renderer agnostic and can be used as platform for any renderer.

If you know React, then you already know Dioxus.

Unique features:

  • Desktop apps running natively (no Electron!) in less than 10 lines of code.
  • Incredibly ergonomic and powerful state management.
  • Comprehensive inline documentation - hover and guides for all HTML elements, listeners, and events.
  • Blazingly fast 🔥🔥 and extremely memory efficient
  • Integrated hot reloading for fast iteration
  • First-class async support with coroutines and suspense
  • And more! Read the full release post.

Supported Platforms

Web
  • Render directly to the DOM using WebAssembly
  • Pre-render with SSR and rehydrate on the client
  • Simple "hello world" at about 65kb, comparable to React
  • Built-in dev server and hot reloading for quick iteration
Desktop
  • Render using Webview or - experimentally - with WGPU or Skia
  • Zero-config setup. Simply cargo-run to build your app
  • Full support for native system access without electron-esque IPC
  • Supports macOS, Linux, and Windows. Portable <3mb binaries
Mobile
  • Render using Webview or - experimentally - with WGPU or Skia
  • Support for iOS and Android
  • Significantly more performant than React Native
Liveview
  • Render apps - or just a single component - entirely on the server
  • Integrations with popular Rust frameworks like Axum and Warp
  • Extremely low-latency and ability to support 10,000+ simultaneous apps
Terminal
  • Render apps directly into your terminal, similar to ink.js
  • Powered by the familiar flexbox and CSS model of the browser
  • Built-in widgets like text input, buttons, and focus system

Why Dioxus?

There's tons of options for building apps, so why would you choose Dioxus?

Well, first and foremost, Dioxus prioritizes developer experience. This is reflected in a variety of features unique to Dioxus:

  • Autoformatting of our meta language (RSX) and accompanying VSCode extension
  • Hotreloading using an interpreter of RSX for both desktop and web
  • Emphasis on good docs - our guide is complete and our HTML elements are documented
  • Significant research in simplifying

Dioxus is also a very extensible platform.

  • Easily build new renderers by implementing a very simple optimized stack-machine
  • Build and share components and even custom elements

So... Dioxus is great, but why won't it work for me?

  • It's not fully mature yet. APIs are still shifting, things might break (though we try to avoid it)
  • You need to run in a no-std environment.
  • You don't like the React-hooks model of building UIs

Contributing

  • Report issues on our issue tracker.
  • Join the discord and ask questions!

License

This project is licensed under the MIT license.

Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in Dioxus by you, shall be licensed as MIT, without any additional terms or conditions.