{"id":13405813,"url":"https://github.com/neon-bindings/neon","last_synced_at":"2025-05-12T16:32:43.914Z","repository":{"id":37445295,"uuid":"42766295","full_name":"neon-bindings/neon","owner":"neon-bindings","description":"Rust bindings for writing safe and fast native Node.js modules.","archived":false,"fork":false,"pushed_at":"2025-05-02T16:40:56.000Z","size":10670,"stargazers_count":8228,"open_issues_count":106,"forks_count":290,"subscribers_count":84,"default_branch":"main","last_synced_at":"2025-05-05T10:16:38.986Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"https://www.neon-bindings.com/","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/neon-bindings.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE-APACHE","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":"AUTHORS.md","dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2015-09-19T08:50:08.000Z","updated_at":"2025-05-04T07:07:51.000Z","dependencies_parsed_at":"2023-02-15T11:31:35.755Z","dependency_job_id":"ef16a5bd-4fa7-4da5-9986-b69e867ab5c0","html_url":"https://github.com/neon-bindings/neon","commit_stats":{"total_commits":1373,"total_committers":78,"mean_commits":"17.602564102564102","dds":0.674435542607429,"last_synced_commit":"69e70ef7f3e5a10f8522398c362c24d5ac394688"},"previous_names":["dherman/nanny","rustbridge/neon"],"tags_count":52,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/neon-bindings%2Fneon","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/neon-bindings%2Fneon/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/neon-bindings%2Fneon/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/neon-bindings%2Fneon/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/neon-bindings","download_url":"https://codeload.github.com/neon-bindings/neon/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":252490467,"owners_count":21756499,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-07-30T19:02:12.612Z","updated_at":"2025-05-05T12:58:42.519Z","avatar_url":"https://github.com/neon-bindings.png","language":"Rust","funding_links":[],"categories":["Rust","Development tools","开发工具 Development tools","开发工具","others","Programming","语言资源库","Packages","包"],"sub_categories":["FFI","FFI FFI","示例 FFI","Rust 🦀","rust","Cross-platform integration","跨平台的集成"],"readme":"# \u003cimg src=\"doc/neon.png\" alt=\"neon\" width=\"100%\" /\u003e\n\n[![Cargo](https://img.shields.io/crates/v/neon.svg)](https://crates.io/crates/neon)\n[![Test Status](https://github.com/neon-bindings/neon/workflows/CI/badge.svg)](https://github.com/neon-bindings/neon/actions?query=workflow%3A%22CI%22)\n[![Lint Status](https://github.com/neon-bindings/neon/workflows/Lints/badge.svg)](https://github.com/neon-bindings/neon/actions?query=workflow%3A%22Lints%22)\n\nRust bindings for writing safe and fast Node.js native addons.\n\n## Getting started\n\nOnce you have the [platform dependencies](https://neon-bindings.com/docs/quick-start) installed, getting started is as\nsimple as:\n\n```\n$ npm init neon my-project\n```\n\nThen see the [Hello World guide](https://neon-bindings.com/docs/hello-world/) for writing your first Hello World in\nNeon!\n\n## Docs\n\nSee our [Neon fundamentals docs](https://neon-bindings.com/docs/intro) and\nour [API docs](https://docs.rs/neon/latest/neon).\n\n## Neon 1.0.0 Migration Guide\n\nThe latest version of Neon, 1.0.0, includes several breaking changes in order to fix unsoundness, improve consistency, and add features.\n\n**Read the new [migration guide](doc/MIGRATION_GUIDE_1.0.0.md)** to learn how to port your \nNeon projects to 1.0.0!\n\n## Platform Support\n\n### Operating Systems\n\n| Linux  | macOS | Windows |\n| ------ | ----- | ------- |\n| ✓      | ✓     | ✓       |\n\n### Node.js\n\nNeon actively supports all current and [maintenance releases of Node](https://github.com/nodejs/LTS#release-schedule). If you're\nusing a different version of Node and believe it should be supported, let us know.\n\nOlder Node version support (minimum v10) may require lower Node-API versions. See the Node [version support matrix](https://nodejs.org/api/n-api.html#node-api-version-matrix) for more details.\n\n### Bun (experimental)\n\n[Bun](https://bun.sh/) is an alternate JavaScript runtime that targets Node compatibility. In many cases Neon modules will work in bun; however, at the time of this writing, some Node-API functions are [not implemented](https://github.com/oven-sh/bun/issues/158).\n\n### Rust\n\nNeon supports Rust stable version 1.65 and higher. We test on the latest stable, beta, and nightly versions of Rust.\n\n## A Taste...\n\n```rust\nfn make_an_array(mut cx: FunctionContext) -\u003e JsResult\u003cJsArray\u003e {\n    // Create some values:\n    let n = cx.number(9000);\n    let s = cx.string(\"hello\");\n    let b = cx.boolean(true);\n\n    // Create a new array:\n    let array = cx.empty_array();\n\n    // Push the values into the array:\n    array.set(\u0026mut cx, 0, n)?;\n    array.set(\u0026mut cx, 1, s)?;\n    array.set(\u0026mut cx, 2, b)?;\n\n    // Return the array:\n    Ok(array)\n}\n\n#[neon::main]\nfn main(mut cx: ModuleContext) -\u003e NeonResult\u003c()\u003e {\n    cx.export_function(\"make_an_array\", make_an_array)?;\n    Ok(())\n}\n```\n\nFor more examples, see our [examples repo](https://github.com/neon-bindings/examples) and [integration tests](test).\n\n## Get Involved\n\nThe Neon community is just getting started and there's tons of fun to be had. Come play! :)\n\nThe [Neon Community Slack](https://rust-bindings.slack.com) is open to all;\nuse [this invite link](https://join.slack.com/t/rust-bindings/shared_invite/zt-1pl5s83xe-ZvXyrzL8vuUmijU~7yiEcg) to receive an invitation.\n\n### Testing Neon\n\nThe Neon project is both an [NPM workspace](https://docs.npmjs.com/cli/v8/using-npm/workspaces) and\na [Cargo workspace](https://doc.rust-lang.org/cargo/reference/workspaces.html). The full suite of tests may be executed\nby installing and testing the NPM workspace.\n\n```sh\nnpm install\nnpm test\n```\n\nIndividual JavaScript packages may be tested with an `npm` workspace command:\n\n```\nnpm --workspace=create-neon test\n```\n\nIndividual Rust crates may be tested with a `cargo` workspace command:\n\n```\ncargo test -p neon-build\n```\n\n## License\n\nLicensed under either of\n\n* Apache License, Version 2.0 ([LICENSE-APACHE](LICENSE-APACHE) or http://www.apache.org/licenses/LICENSE-2.0)\n* MIT license ([LICENSE-MIT](LICENSE-MIT) or http://opensource.org/licenses/MIT)\n\nat your option.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fneon-bindings%2Fneon","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fneon-bindings%2Fneon","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fneon-bindings%2Fneon/lists"}