Skip to content

Installation ​

Run from a checkout ​

Use Node.js 22.12 or newer and npm:

sh
npm ci
npm run dev

npm run dev starts the developer documentation at http://localhost:4175/. npm run docs:dev is equivalent; npm run docs:build produces static output. For the application, see the implementation repository.

Install into a separate project ​

The package is private. Build and pack it locally:

sh
npm run build:packages
mkdir -p /tmp/grabm-package
npm pack -w @grabm/abm --pack-destination /tmp/grabm-package

In a new consumer directory:

sh
npm init -y
npm pkg set type=module
npm install /tmp/grabm-package/grabm-abm-0.1.0.tgz

Simulation and analytics require no rendering dependencies. For browser playback:

sh
npm install three
npm install -D vite typescript @types/three
# Only for the Plotly import:
npm install plotly.js-basic-dist-min

See compatibility and import paths. Tests install the tarball into an independent consumer, first without optional peers and then with browser dependencies.

Documentation for the grABM library.