đ¤¯ zART-stack â Zero-API, React [Native], & TypeScript
âšī¸âšī¸âšī¸ This example project is not actively maintained and is using an old version (v9) of tRPC âšī¸âšī¸âšī¸
If you're looking for alternatives, have a look at https://github.com/t3-oss/create-t3-turbo and other reference projects on https://trpc.io/docs/awesome-trpc
Zero-API, React, & TypeScript
âĄī¸ Probably the fastest way to build a React Native app with your own backend âĄī¸
A monorepo containing:
In tRPC you simply write API-functions that are automatically inferred straight into your frontend - no matter if it's React, React Native, or something else (that is TS/JS-based).
Very rough video recorded in 2 minutes đ
You will need docker compose to run the postgres database. It comes with the Docker Desktop App
git clone [email protected]:KATT/zart.git
cd zart
yarn
yarn dev
Press
i
afteryarn dev
in to launch the iOS Simulator.
Now - head over to one of the ./apps
, whilist updating a router in tRPC or the Database Schema and see that the data is directly inferred.
Command | Description |
---|---|
yarn dev |
Starts Postgres, Expo & Next.js |
yarn db-up |
Starts Postgres on port 5466 |
yarn db-migrate-dev |
Runs the latest Database migrations after updating the Prisma schema |
yarn db-nuke |
Stops and deletes the the database |
.
âââ apps
â âââ expo # Expo/RN application
â âââ nextjs # Server-side rendered Next.js application
âââ packages
â âââ api # tRPC API
â âââ react # Shared React-helpers
â âââ react-native # RN components. **Could** be shared between Expo & Next.js if you're in to that sort of thing.
âââ prisma # Prisma setup
DATABASE_URL
pointing towards that dbapps/nextjs
and tick Include source files outside of the Root Directory in the Build Step.Shoot me a message on Twitter!
apps/expo
is basically a copy-paste from expo-next-monorepo-example
by axeldelafosse.