rxf-cli-0.1.0 is not a library.
中文版本:README.zh.md
rxf CLI
Command-line tool for the RXF SDK. Scaffold new projects, start the development server, and build production binaries — all without touching Flutter or Rust directly.
Prerequisites
- Flutter SDK >= 3.5.0
- Rust toolchain
- rinf CLI (global install):
Installation
Commands
rxf create <name>
Scaffold a new RXF application:
Generated project structure:
hello_rxf/
├── package.json # Frontend toolchain config (optional prettier/eslint)
├── rxf.config.json # Global config (app name, appId, etc.)
├── jsconfig.json # JS/JSX type hint config
├── types/
│ └── rxf-jsx.d.ts # JSX component type definitions
└── src/
└── pages/ # Business logic: UI and page logic
└── home/
├── ui.jsx # Page UI (JSX component tree)
└── logic.js # Page logic (event handlers, data binding)
rxf dev
Start the development server.
The CLI automatically creates a hidden .rxf/ workspace, assembles and compiles the underlying Flutter/Rust dependencies, and launches the app:
Press r to restart the app. The .rxf/ workspace is created on first run and reused on subsequent runs.
rxf build
Build the application for production:
Build artifacts are copied to the build/ directory in your project (e.g. build/rxf_runner.app).
How It Works
rxf dev/rxf buildimplicitly generate and maintain a.rxf/folder in your project. This folder contains a complete Flutter host app and a Rust rinf hub.- The Flutter package (
rxf) and Rust crate (rxf) versions used in.rxf/are read automatically from the published package manifests at CLI compile time. src/pages/JSX/JS files are loaded at runtime (native) or embedded at compile time (WASM) via theinclude_pages!macro in the Rust hub.- The Rust hub embeds QuickJS to execute page logic and communicates with Flutter via rinf signals.