2021-01-16 04:32:53 +00:00
< div align = "center" >
2021-01-20 17:12:48 +00:00
< h1 > 📦✨ dioxus-cli< / h1 >
2021-01-16 04:32:53 +00:00
< p >
2021-01-20 17:12:48 +00:00
< strong > Tooling to supercharge dioxus projects< / strong >
2021-01-16 04:32:53 +00:00
< / p >
< / div >
# About
---
2021-01-20 17:12:48 +00:00
dioxus-cli (inspired by wasm-pack and webpack) is a tool to help get dioxus projects off the ground. It handles all the build, development, bundling, and publishing to make web development just a simple two commands: `cargo init` and `dioxus-cli publish` .
2021-01-16 04:32:53 +00:00
Best thing:
- No NPM.
- No Webpack.
- No `node_modules` .
- No Babel
- No parcel
- No rollup
- No ESLint
2021-01-20 17:12:48 +00:00
Just install Rust, dioxus-cli, and you're good to go.
`cargo install --git github.com/jkelleyrtp/dioxus-cli`
2021-01-16 04:32:53 +00:00
Need a development server?
2021-01-20 17:12:48 +00:00
`dioxus develop`
2021-01-16 04:32:53 +00:00
Need to run an example?
2021-01-20 17:12:48 +00:00
`dioxus develop --example textbox`
2021-01-16 04:32:53 +00:00
Need to benchmark a component?
2021-01-20 17:12:48 +00:00
`dioxus bench`
2021-01-16 04:32:53 +00:00
Need to test your code?
2021-01-20 17:12:48 +00:00
`dioxus test`
2021-01-16 04:32:53 +00:00
Need to build your code into a bundle?
2021-01-20 17:12:48 +00:00
`dioxus build --outdir public`
2021-01-16 04:32:53 +00:00
Need to publish your code to GitHub pages, Netlify, etc?
2021-01-20 17:12:48 +00:00
`dioxus publish --ghpages myrepo.git`
2021-01-16 04:32:53 +00:00
# Use in your project
---
2021-01-20 17:12:48 +00:00
Sometimes you'll want to include static assets without bundling them into your .wasm content. dioxus-cli provides a few ways of doing this:
2021-01-16 04:32:53 +00:00
2021-01-20 17:12:48 +00:00
- Load in dynamic content using `dioxus::asset("./static/images/blah.svg")`
- Live-reload HTML templates without rebuilding your .wasm with `dioxus::template("./templates/blah.html")`
- Use a CSS library like tailwind in your dioxus configuration with