Sync engine for building fast and scalable fullstack applications.
Based on Linear architecture (see: Scaling the Linear Sync Engine).
Design doc: https://docs.google.com/document/d/1bRGZz7YL1sd_YNg3AiyfbPUT2cLwgcOtFyp1dcpaqGI/edit?usp=sharing
Install deps
$ npm install
Run dev build.
$ npm run dev
Then navigate to localhost:8080
. localhost:8080/api/graphql
can be used to load the graphql explorer.
This project uses prisma
as an ORM to manage db connections, create schemas and models, and run queries. It's pretty nifty and works quite well with TypeScript! See https://www.prisma.io/.
- To run a migration:
$ npx prisma migrate dev --name <migration name>
- To re-generate types for
prisma/client
:
$ npx prisma generate
- To generate graphql types from queries. (note: server needs to be runnning)
$ npm run codegen
TODO: should automate some of these steps in the build pipeline