A web application for DKP, built with React, NextJS, TypeScript and Material UI.
Each instance of this project is deployed to Vercel.
If you'd like help deploying an instance for your guild, please open an issue and we'll be happy to help.
Managing a local development environment is done via the Makefile, see make help
for more details.
To initialize your development environment:
# Install nvm
wget -qO- https://raw.githubusercontent.com/nvm-sh/nvm/v0.39.7/install.sh | bash
# Use the required version
nvm install
nvm use
# Install local dependencies
make local-setup
Before running the app, you will need to make a copy of .env.example
named .env
and provide appropriate values for the fields marked CHANGE_ME
.
By default, the app runs locally against a local postgres database.
make local-run
The application will be available at localhost:3000.
You can seed the local database with some useful test characters and raid activities by running:
make db-testdata
If you use EQ DKP Plus, you can import data from that system by running:
make db-etl-eqdkp
There are two easy ways to run the app with an attached debugger.
- Browser Debugger If you wish to debug the client, you can drop the
debugger
keyword into any client code and Chrome will interpret the keyword as a break-point. You can use Chrome as your debugging environment. - VSCode Debugger If you wish to debug the server (or client), you can use the provided VSCode launch.json configuration. Select the
Run and Debug
side-bar item and click play. Add break-points where desired.
TODO: Write some tests.
Playwright will be used for browser-based tests.
husky is used to automatically format code using a pre-commit git hook, which runs every time you run git commit
.
This project uses yarn
.
Dependencies used for release are specified in package.json
under the dependencies
section. All other dependencies are specified under the devDependencies
section.
This project uses prisma
.
To generate a migration, add, remove or edit model files in prisma/schema
and then run make db-migrate
.
To run locally, the app requires some secrets to be injected from environment variables. Specify them in .env
file. See the .env.example
file for details.
The core technologies used in this application are:
Library | Description |
---|---|
Typescript | Strongly typed language with JavaScript transpiler |
NextJS | Opinionated web framework to simplify dev, build & test tooling |
React | Library for building user interfaces |
tRPC | Library for typesafe API |
Prisma | ORM for managing database migrations |
Material UI | Design system implementation |
Playwright | Library for writing and running tests |