尚未收集仓库信息。
尚未检测到更新。GitHub 发布版本后会显示在这里。
制作者的介绍仅有上面的一句话。 更多详情请阅读仓库 README。 仓库 README ↗
正在加载完整 README。
查看完整 README ↗A modular HTML/CSS rendering engine
Talk to us in: the #native channel in the Dioxus Discord
Blitz is currently in a beta state. It can already render many popular no-JS websites (Wikipedia, (Old) Reddit, etc), and is usable for making apps if you are an early adopter and willing to live on the bleeding edge. But there are also still many bugs and missing features. We are actively working on bringing it up to production quality.
Check out:
cargo run -rp browsercargo run -rp rdme ./README.mdcargo run -rp todomvccargo run -rp wgpu_textureOther examples are available in the examples/ folder.
Blitz is designed to render HTML and CSS - we don't want to support the entirety of browser features (or at least we want to make all such "extra" features opt-in). In our opinion, the browser is bloated for the basic use case of rendering HTML/CSS.
We do intend to support:
Notably we don't provide features like webrtc, websockets, bluetooth, localstorage, etc. In a native app, much of this functionality can be fulfilled using regular Rust crates and doesn't need to be coupled with the renderer.
We don't yet have Blitz bindings for other languages (JavaScript, Python, etc) but would accept contributions along those lines.
Blitz consists of a core DOM abstraction; several modular pieces which provide additional functionality like networking, rendering, windows, and state management; and two high-level wrappers that support rendering either a Dioxus application or HTML with a simplified API.
These pieces can be combined together to make a cohesive web engine.
blitz - An HTML/markdown frontend that can render an HTML string. This is useful for previewing HTML and/or markdown files but currently lacks interactivity.
Uses: blitz-dom, blitz-html, blitz-shell, blitz-renderer-vellodioxus-native - A Dioxus frontend that can render a Dioxus VirtualDom. This has full interactivity support via Dioxus's event handling.
Uses: blitz-dom, dioxus-core, blitz-shell, blitz-renderer-velloBoth wrappers can optionally use blitz-net to fetch sub-resources.
The latest development version of the Dioxus Native lives in this repository. As Dioxus Native is under rapid development it can be useful to use this version to get access to the latest features and bug fixes sooner than they are available in an official release.
To use the git version of dioxus-native:
dioxus crate entirely.dioxus-native = { git = "https://github.com/DioxusLabs/blitz", rev = "e64a3d8", features = ["prelude"] }e64a3d8 with the git commit id of the version you want to use)use dioxus::prelude::* to use dioxus_native::prelude::*.dioxus crate that is not exported from the Dioxus Native prelude then you can import it from the individual sub-crates (dioxus-html, dioxus-signals, dioxus-router, etc) instead.The git versions of Dioxus Native currently depend on Dioxus 0.8.0-alpha.3 from crates.io (commits before 286874c use the stable v0.7.x version), so any additional libraries that you are using (dioxus-sdk, dioxus-components, dioxus-free-icons, etc) need to be versions that work with Dioxus 0.8.0-alpha.3.
blitz-dom - The core DOM abstraction that includes style resolution, layout and event handling (but not parsing, rendering or system integration).
Uses: Stylo (CSS parsing/resolution), Taffy (box-level layout), Parley (text layout)blitz-traits - Minimal base crate containing types and traits to allow the other crates to interoperate without depending on each otherblitz-net - Networking that can fetch resources over http, from the file-system or from encoded data URIs.
Uses: reqwest (HTTP client)blitz-paint - Translates a blitz-dom tree into anyrender draw commands.
Uses: anyrender (2D drawing abstraction)blitz-html - Adds HTML parsing to blitz-dom
Uses: html5ever (HTML parsing) and xml5ever (XHTML parsing)blitz-shell - A shell that allows Blitz to render to a window (integrates a Winit event loop, AccessKit, Muda etc).
Uses: winit (windowing/input), accesskit (accessibility), muda (system menus)The AnyRender rendering abstraction now lives in it's repository over at https://github.com/dioxuslabs/anyrender
This project is dual licensed under the Apache 2.0 and MIT licenses.
The stylo_taffy crate is ADDITIONALLY licensed under MPL 2.0 (so it is triple licensed under Apache 2.0, MIT, and MPL 2.0 licenses) for easier interop with the Servo project.
Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in Blitz by you, shall be dual licensed as Apache 2.0 and MIT (and MPL 2.0 if submitted to the stylo_taffy crate), without any additional terms or conditions.