Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,9 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

## [Unreleased]

Bugfixes:
* Fix `halogen:dev` script (#1427)

## [1.0.5] - 2026-10-13

Bugfixes:
Expand Down
20 changes: 20 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,26 @@ SPAGO_TEST_DEBUG=1 spago
SPAGO_TEST_ACCEPT=1 spago
```

## Developing the `spago docs` Halogen app

The `spago docs` command generates a "project-local Pursuit"--package docs as HTML files. The docs HTML also includes a `docs-search-app.js` for search functionality, and that is a compiled Halogen app. The source for the app is in `docs-search/client-halogen`. To develop that locally, run the same install and bootstrap scripts as above

```shell
npm ci
spago bundle -p spago-bin
```

then generate the initial app bundle and Spago's own docs

```bash
./bin/index.dev.js bundle -p docs-search-client-halogen
./bin/index.dev.js docs
```

That will output a link like `file://path/to/spago/generated-docs/html/index.html` where you can view the generated docs. Then run `npm run halogen:dev`, make edits to `docs-search/client-halogen`, and reload the browser to see changes.

The script bundles the Halogen app in watch mode, so it updates whenever `output/` changes (which happens on edit, if your editor has the language server installed).

## Developing docs

If you edit any title in the readme, run `doctoc` to update the Table of Contents:
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
"format:check": "purs-tidy check core src bin docs-search test",
"bundle": "spago bundle -p spago-bin",
"prepublishOnly": "spago build && ./bin/index.dev.js bundle -p spago-bin && ./bin/index.dev.js bundle -p docs-search-client-halogen",
"halogen:dev": "./bin/index.dev.js bundle -p docs-search-client-halogen --outfile=./generated-docs/html/docs-search-app.js --bundler-args '--watch=forever' --bundler-args '--servedir=./generated-docs/html'"
"halogen:dev": "./bin/index.dev.js bundle -p docs-search-client-halogen --outfile=../../generated-docs/html/docs-search-app.js --bundler-args '--watch=forever'"
},
"dependencies": {
"@nodelib/fs.walk": "^3.0.1",
Expand Down
Loading