Skip to content
Getting startedInstall

Install

Add Mokly to the repository that holds the components your screens are made of.

Install the package

Mokly runs from your own repository as a development dependency.

shell
npm install --save-dev @mokly/mokly

An HTML-only catalogue needs neither React nor React DOM. Screens and components written in React need React and React DOM 19 or newer in your repository. Install them when your repository does not have them yet:

shell
npm install --save-dev react react-dom

The package is @mokly/mokly and its executable is mokly. This documentation describes version 0.18.0.

Run the command

Run the local executable with npx. In a repository that has Mokly as a development dependency, --no-install keeps npm from reaching the registry.

shell
npx --no-install mokly --version

On a machine without the dependency you can run one published release directly:

shell
npx --package @mokly/mokly mokly --help

Pin a version

To reproduce one exact release, on another machine or in a job, install the version rather than the range:

shell
npm install --save-dev @mokly/[email protected]

What you need

  • Node.js 22.15 or newer, excluding Node 23 and Node 24.14 through 24.18. If you use Node 24, select 24.19 or later to avoid the affected runtime releases.
  • A repository that holds your screens and components, or somewhere to write new ones.
  • Git, once you want to compare a branch with its base.

Next

Configure where Mokly finds your screens.