Files
archived-starters/javascript/with-prisma
dependabot[bot] 74385dfdcc Bump node-fetch from 2.6.0 to 2.6.1 in /javascript/with-prisma (#12)
Bumps [node-fetch](https://github.com/bitinn/node-fetch) from 2.6.0 to 2.6.1.
- [Release notes](https://github.com/bitinn/node-fetch/releases)
- [Changelog](https://github.com/node-fetch/node-fetch/blob/master/docs/CHANGELOG.md)
- [Commits](https://github.com/bitinn/node-fetch/compare/v2.6.0...v2.6.1)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-09-13 12:58:01 +01:00
..
2020-09-11 19:02:13 +01:00
2020-09-11 19:02:13 +01:00
2020-09-11 19:02:13 +01:00
2020-09-11 19:02:13 +01:00
2020-09-11 19:02:13 +01:00

with-prisma

This example uses Prisma to access and interact with the Railway PostgreSQL database.

Usage

  • Install dependencies yarn install
  • Init a Railway project yarn railway init
  • Generate Prisma yarn generate
  • Open the project in the Railway dashboard yarn railway open
  • Run the code yarn start

Optionally, run yarn migrate:up to create a Users and Posts folder and follow Prisma's Quickstart!

Prisma support

Prisma has fantastic TypeScript support. If you open src/index.ts in an editor like VSCode, you will get autocompletion and type hints when querying the database.

All of Prisma features are supported. [Prisma documentation can be found here](More information.

You can edit the Prisma schema at prisma/schema.prisma. After editing you can run

yarn migrate:save
yarn migrate:up

to create new migrations and run them against the database.

You should also run yarn generate to create updated type definitions for the Prisma client.