Prerequisites
Before you begin, make sure you have the following installed:- Dota 2 — installed via Steam. The postinstall script locates your Dota 2 directory automatically using
find-steam-app. - Node.js — used to run the install and launch scripts.
- Git — used to clone the repository.
Setup
Install dependencies
Run The
npm install from the project root:postinstall script (scripts/install.js) runs automatically after installation. It locates your Dota 2 game directory via Steam and creates the necessary symlinks so the addon is available when you launch the game.If the postinstall script fails, verify that Dota 2 is installed through Steam and that your Steam library path is accessible.
Code style
The project uses Prettier for consistent formatting. The configuration lives in.prettierrc.json:
.prettierrc.json
pretty-quick --staged automatically before each commit, so staged files are formatted before they land in version control. You don’t need to run Prettier manually.
To check formatting across the entire project without committing:
Editor config
An.editorconfig file is included to keep whitespace consistent across editors:
| Setting | Value |
|---|---|
| Charset | utf-8 |
| Indent style | Tab |
| Indent size | 4 |
| Line endings | CRLF |
| Final newline | Yes |
YAML and Markdown files (
.yml, .yaml, .md) use spaces with an indent size of 2, overriding the tab default.
