Next.js PostGraphile Starter
A quick-start template for full-stack application development using React, Node.js, GraphQL and PostgreSQL utilizing the Next.js framework and PostGraphile.
Prerequisites
- Node.js 12.22.0 or later
- PostgreSQL database
Getting Started
- Run
yarn
to install dependencies - Create your
.env.local
file:cp .env.local.template .env.local
- Run
yarn dev
to start the development server
GraphQL Routes
- GraphQL - http://localhost:3000/api/graphql
- GraphiQL - http://localhost:3000/api/graphiql
Tech Stack
This tech stack allows for rapid and maintainable application development because you will be writing less code using these tools!
- Apollo Client - Fetch, cache, and modify application data from a GraphQL API
- GraphQL Code Generator - Generate typings and React hooks for your GraphQL API and queries
- Next.js - React framework for full-stack applications
- PostGraphile - Automatic GraphQL API based on a PostgreSQL schema
- PostgreSQL - Database
- TypeScript - Strongly type your codebase
Where to go from here?
This is a bare template that sets up the tooling needed for this tech stack. From here, you should start designing your PostgreSQL schema, which in turn, creates your GraphQL API. Then you can start builing the UI for your application.