Skip to content
This repository has been archived by the owner on Oct 16, 2024. It is now read-only.

LedgerHQ/innovation-voucher-web

Repository files navigation

Voucher Web

This is a Next.js project bootstrapped with create-next-app.

Getting Started

npm install
cp .env.example .env.local

Edit .env.local file

Run the development server:

npm run dev
# or
yarn dev

Open http://localhost:3000 to EIP-712 sign a voucher redeem operation

Git hooks

We use lefthook to manage our git hooks. For the moment, the following hooks are configured:

  • Run npm run lint before pushing to remote
  • Run npm run prettier before pushing to remote
  • Run npm run ts:check before pushing to remote

How to install

You only need to do this step once. Run npx @arkweid/lefthook install in the root of the repository to install the git hooks described in the lefthook.yml file.

How to run manually

You can manually run the installed git hooks by running npx @arkweid/lefthook run pre-push or by running the alias defined in the package.json file (npm run lefthook).

Docker

Build

docker build . -f ./Dockerfile -t web-voucher:0.2

Run locally

docker run -p 3000:3000 web-voucher:0.2