JSPM

  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 12
  • Score
    100M100P100Q41756F
  • License MIT

โšก A powerful CLI to convert your Next.js App Router project into a fully functional React Native Expo app.

Package Exports

  • ntrn

Readme

๐Ÿš€ next-to-react-native

  _   _ _____ ____  _   _ 
 | \ | |_   _|  _ \| \ | |
 |  \| | | | | |_) |  \| |
 | |\  | | | |  _ <| |\  |
 |_| \_| |_| |_| \_\_| \_|

Effortlessly convert your Next.js App Router project into a fully functional React Native Expo app using this zero-config CLI tool.

version license stars


โœจ Features

  • โšก๏ธ Instantly converts your Next.js app/ directory to React Native screens
  • ๐Ÿ“ฆ Transforms layout.tsx into App.tsx
  • ๐ŸŽฏ Handles page.tsx and routes into Expo-compatible screens
  • ๐Ÿง  Powered by Gemini API for JSX โ†’ React Native conversion
  • ๐ŸŽจ Tailwind CSS support via NativeWind
  • ๐Ÿ—‚ Creates React Native standard structure (screens, assets, etc.)
  • ๐Ÿ“‹ Outputs required dependencies in requirements.txt

๐Ÿ“ฆ Installation

You will require:

  1. Node JS
  2. Gemini API
  3. clone repo from GitHub.

Process to work on.

  1. Update .env file from project
  2. npm link
npm install -g ntrn

After installing and setting up repo and .env

to update the ntrn

npm link

๐Ÿš€ Quick Start

ntrn

Run this command inside the root of your Next.js App Router project.
It will generate a complete Expo React Native app inside converted-react-native/.


๐Ÿ“‚ File & Folder Mapping

From (Next.js) To (React Native)
app/layout.tsx App.tsx
app/page.tsx screens/HomeScreen.tsx
public/ assets/
@/components/* Preserved and reused

โš™๏ธ CLI Options

ntrn --help
Option Description
--version Show CLI version
--convert Convert app/ directory to React Native
--tailwind Enable Tailwind detection (NativeWind auto)

๐Ÿ“ธ Terminal Demo

demo


๐Ÿง  Powered By


๐Ÿงช Roadmap

  • Automatic dependency installation (optional)
  • Tailwind class converter (full support)
  • CLI config file support
  • Auto-detect pages/ routing fallback
  • Dark mode README and Docs

๐Ÿค Contributing

We love contributions!
Please check out our CONTRIBUTING.md before submitting a pull request.

You can:

  • Open issues ๐Ÿ›
  • Suggest new features ๐ŸŒŸ
  • Improve the CLI or documentation ๐Ÿ› 

๐ŸŒ Community

Join discussions, ask questions, and share ideas:


๐Ÿ“ซ Stay in Touch

If you like this project, show some โค๏ธ

  • โญ Star the repo
  • ๐Ÿฆ Tweet about it
  • ๐Ÿ“ข Share with your team

๐Ÿ“„ License

This project is licensed under the MIT License.
Do whatever you want, just give credit.


Made with ๐Ÿ’™ by Ammey Kuraaday