Next-gen itdagene webapp
Clone or download
odinuge Merge pull request #55 from itdagene-ntnu/doppins/flow-bin-from-0.90.…
…0-below-0.91.0

[Doppins] Upgrade dependency flow-bin to ^0.91.0
Latest commit 34e8e9f Jan 21, 2019

README.md

itDAGENE-webapp

nextgen itDAGENE frontend

Picture of the page

Written using next.js, react-relay and graphql.

Setup

$ yarn
$ yarn schema:prod # replace 'prod' with 'dev' when running backend
$ yarn relay

Development

$ yarn dev
$ # open http://localhost:8000
$ # To run against itdagene.no:
$ RELAY_ENDPOINT=https://itdagene.no/graphql yarn dev

Config

  • RELAY_ENDPOINT: graphql endpoint for relay (default: http://localhost:8000)
  • RAVEN_PUBLIC_DSN: Public Sentry Raven DSN
  • RAVEN_DSN: Sentry Raven DSN

Code style

The source code is formatted with prettier, and use eslint for basic linting. To verify that your code is good to go, you have to execute the following commands:

$ yarn schema:prod
$ yarn relay
$ yarn lint
$ yarn test
$ yarn build

Running in production

In order to run in production, you have to build and then server the SSR. This project ships with a Dockerfile meant for building and running the project.

$ yarn build
$ RELAY_ENDPOINT=... yarn start
$ # using docker
$ docker build -t itdagene/itdagene-webapp .