Rust bindings for writing safe and fast native Node.js modules.
Neon is a Rust library that provides bindings for writing native Node.js modules, allowing developers to extend Node.js with high-performance Rust code. It solves the problem of CPU-intensive JavaScript bottlenecks by enabling safe, fast native extensions. The project uses Node-API for stable cross-version compatibility and integrates seamlessly with the Node.js ecosystem.
Node.js developers who need to write performance-critical native addons, and Rust developers looking to integrate with JavaScript runtimes. It's ideal for teams building data processing, cryptography, or other computationally heavy modules.
Developers choose Neon because it combines Rust's memory safety and performance with Node.js's flexibility, reducing the risk of crashes and security vulnerabilities common in C/C++ addons. Its use of Node-API ensures long-term compatibility and easier maintenance compared to lower-level alternatives.
Rust bindings for writing safe and fast native Node.js modules.
Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.
Leverages Rust's ownership and type systems to prevent common memory bugs, as emphasized in the key features for safe Rust bindings, reducing crash risks in native modules.
Uses Node-API for compatibility across Node.js versions and supports Linux, macOS, and Windows, ensuring long-term maintainability per the platform support section.
Works with Rust stable 1.65+ and is tested on stable, beta, and nightly toolchains, allowing developers to use up-to-date Rust features without compromise.
Provides a simple API for creating JavaScript values and arrays from Rust, as shown in the 'Taste' code snippet with easy array manipulation methods like cx.empty_array().
Version 1.0.0 introduced several breaking changes, requiring migration efforts for existing projects, as admitted in the migration guide, which can delay updates.
Bun support is experimental with missing Node-API functions, hindering use in alternative JavaScript runtimes, as noted in the platform support section.
Requires installing platform dependencies and managing both Rust and Node.js toolchains, making setup more involved than pure JavaScript modules, as implied in the quick-start guide.