create-nitro-project
v0.0.1
Published
A CLI to create production-grade React Native Nitro Modules
Maintainers
Readme
create-nitro-project
The fastest way to scaffold production-grade React Native Nitro Modules.
Hey there! Welcome to create-nitro-project.
If you're looking to build high-performance native modules for React Native without the headache, you're in the right place. This CLI handles all the boring setup so you can focus on the fun part—writing C++, Swift, or Kotlin code that runs blazing fast.
Why Nitro?
Nitro Modules are the next big thing. Seriously.
- Zero Overhead: No bridge. Just direct, synchronous calls via JSI.
- Type-Safe: We generate bindings for you. TypeScript <-> Native. No guesswork.
- Modern: Built for the future of React Native (Bridge-less).
Features
- Instant Scaffolding: One command, and you have a full monorepo ready to go.
- Cross-Platform: Android, iOS, macOS, Windows? We got you.
- Your Language, Your Choice:
- Android: Love Kotlin? Go for it. Need raw C++ power? We support that too.
- iOS: Swift by default, but fully C++ compatible.
- Premium DX:
- Monorepo: Smart setup with Bun/NPM workspaces.
- Linting: Pre-configured ESLint & Prettier. No bike-shedding.
- Example App: Comes with a working app to test your module immediately.
Prerequisites
Just make sure you have the basics:
- Node.js 18+ or Bun 1.0+
- Xcode (for iOS/macOS dev)
- Android Studio (for Android dev)
Usage
We made this super easy. Just run:
npx create-nitro-project@latest
# or if you prefer Bun (we do!)
bun create nitro-projectInteractive Mode
The CLI is friendly! It will ask you a few questions:
- Name: What do you want to call your cool module?
- Languages: Kotlin or C++? Swift or C++?
- Addons: Need macOS support? Just check the box.
For CI / Robots
Want to skip the chat? You can pass arguments directly:
npx create-nitro-project MyFastModule \
--android kotlin \
--ios swift \
--addon macos windows \
--author "Your Name" \
--author-url "https://github.com/you" \
--repo-url "https://github.com/you/repo"What Do You Get?
A clean, modern monorepo structure:
MyFastModule/
├── packages/
│ └── my-fast-module/ # Here is your code!
│ ├── src/ # TypeScript specs
│ ├── android/ # Native Android implementation
│ ├── ios/ # Native iOS implementation
│ └── nitro.json # Generator config
├── example/ # Run this to test your changes
├── node_modules/ # Dependencies
└── package.json # Workspace rootHow to Develop
- Define your API in
src/specs/MyModule.nitro.ts. - Generate bindings:
bun run build - Write Native Code: Implement the interface in
android/andios/. - Run the Example:
bun run example start
Acknowledgements
Huge shoutout to margelo/react-native-quick-crypto for the inspiration and boorad for the groundwork.
License
MIT © Athex Web3
Built with love for the React Native community.
