There's a client and server side to Hatchet. The server starts at /
and runs on Node Express. There is no server-side rendering. All that's done on the client, in React. The client is located in /client
.
- Navigate to project root and run
yarn install
. - Create
.env
and fill it with necessary credentials.EMAIL_USER
andEMAIL_PASS
come from the Ethereal mail account you'll need to create here. Well, you'll need to create it to get emails sending when you're in the dev environment. While in the dev environment, emails are trapped using the aforementioned service and are not real outside of the production environment. If you open up the terminal after a sent email in dev mode, you'll see a URL you can visit to see an email preview.ROOT_URL
is used to redirect back to the web app from the test email links. Finally,JWT_SECRET
is used when creating tokens during account login. Create an arbitrary value here.
EMAIL_USER=<SOME_KEY>@ethereal.email
EMAIL_PASS=<SOME_PASSWORD>
JWT_SECRET=<WHATEVER_YOU_WANT_IT_TO_BE>
ROOT_URL=http://localhost:3000
- Navigate to
/client
- Create
.env
and add the following key/value:SKIP_PREFLIGHT_CHECK=true
. This helps to resolve anes-lint
issue during package installation. - From the same directory, run
yarn install
- Open up two tabs in the terminal—one for the server and one for the client.
- In tab 1, to project root and run
yarn start
. - In tab 2, navigate to
/client
and runyarn start
.
You should see a new instance of Hatchet running at http://localhost:3000
.
Done!