r2n
v0.1.0
Published
Rapidly ship Rust projects to npm
Downloads
2
Readme
r2n
Ship Rust CLI tools to npm.
⚠️ EXPERIMENTAL: This package is experimental and should not be used in production. APIs and behavior may change without notice.
Install
cargo install r2nUsage
Create a new project
r2n init my-tool
cd my-toolAdd to existing Rust project
cd my-rust-project
r2n addBuild
r2n buildThis cross-compiles your Rust binary and creates an npm package ready to publish.
What it does
- Creates
package.jsonwith proper bin configuration - Generates a Node.js wrapper script
- Cross-compiles your Rust binary for multiple platforms
- Outputs to
dist/ready for npm publish
License
MIT OR Apache-2.0
