Thank you for investing your time in contributing to our project! If you are a first-time contributor to this project, please take a look at the Get Started section 😀
Caution
|
All commands in this README document are to be executed from the project root directory (where this document resides). |
This project uses the zero-install feature of the Yarn package manager.
Upon cloning the Git repository, the .yarn/cache
directory already contains a cache of the third-party dependencies, effectively replacing the usual node_modules
directory.
-
macOS and Linux users should install Node.js via Node Version Manager and opt for Yarn via Corepack:
curl https://raw.githubusercontent.com/nvm-sh/nvm/master/install.sh | bash source ~/.bashrc nvm install --lts corepack enable yarn yarn run setup
-
Windows users should install Node.js via Windows Package Manager and install Yarn via npm (which is actually a workaround until Corepack supports Windows):
winget install OpenJS.NodeJS.LTS npm install --global yarn yarn run setup
-
Generate an SSH key with the Ed25519 algorithm, for example using ssh-keygen or 1Password, and add it to the SSH agent on your computer. If you already have an SSH key on your computer, you may skip this step.
ssh-keygen -t ed25519 -f "$HOME/.ssh/<my-ssh-key>" ssh-add ~/.ssh/<my-ssh-key>
-
Windows users must instruct Git to use Microsoft OpenSSH as the SSH agent:
git config --global core.sshCommand "C:/Windows/System32/OpenSSH/ssh.exe"
-
-
Grab the public key. It appears like
ssh-ed25519 AAAAC3(…)
.cat ~/.ssh/<my-ssh-key>.pub
-
Register the public key in GitHub as a signing key.
-
Obtain your noreply email address on GitHub. It appears like
<id+username>@users.noreply.github.com
. -
Declare your identity within the scope of this repository and use the public key to sign your commits:
git config user.name "<FirstName> <LastName>" git config user.email "<id+username>@users.noreply.github.com" git config user.signingkey "ssh-ed25519 AAAAC3<PublicKey>" git config gpg.format "ssh" git config commit.gpgsign "true" git config tag.gpgsign "true"
-
Open the project directory:
idea .
-
Follow the popup message to install the recommended plugins automatically. Alternatively, go to File › Settings › Plugins and install them manually.
-
Go to File › Settings › Languages & Frameworks › Node.js. Select the appropriate Node.js interpreter and enable coding assistance.
The scripts
field in package.json
defines a set of work tasks.
Corresponding configurations for IntelliJ IDEA and Visual Studio Code are located in .idea/runConfigurations
and .vscode/tasks.json
, respectively.
-
Source code formatting via Prettier (
validate.format
).-
validate.format.fix
reformats the files accordingly. -
validate.format.nocache
runsvalidate.format
without caching which is encouraged after an adjustment to the formatting configuration.
-
If import statements are full of squiggly red lines, and IntelliJ IDEA claims that external modules or third-party dependencies are not installed, try the following steps:
-
In the project root directory, delete the
.yarn
directory and the.pnp.cjs
,.pnp.loader.mjs
, andyarn.lock
files. -
Roll back the deletion in Git to restore the files. This triggers re-indexing in IntelliJ IDEA.
-
Go to Help › Find Action and search for
Restart TypeScript Service
.