Development – inksane
inksane
Get Involved

Development

Set up the repository locally and run the checks before you open a pull request.

Requirements

Setup

Clone the repository, install the dependencies, and run the full validation suite:

pnpm install
pnpm ready

pnpm ready runs the type checks and linter, the tests, and the production build.

Repository layout

PathWhat it is
packages/coreThe editor, BaseKit, feature extensions, and commands.
packages/reactThe React bindings.
packages/extension-collaborationThe Yjs collaboration extension.
apps/playgroundThe Astro playground with demos and examples.
apps/docsThis documentation site.

Scripts

CommandWhat it does
pnpm devRuns the playground locally.
pnpm dev:docsRuns this documentation site locally.
pnpm buildBuilds the published packages.
pnpm readyType checks, tests, and builds. Run this before a PR.
pnpm release:addCreates a bump file for a release.
pnpm release:checkValidates the release metadata.
pnpm release:statusShows the pending releases.

Package-specific scripts work through pnpm filters, for example pnpm --filter @inksane/core test.

Documentation

The docs are Markdown and MDX under apps/docs/content/docs. Run pnpm dev:docs and edit the files; the dev server reloads them.

Navigation lives in the meta.json file next to the pages:

{
  "title": "Introduction",
  "collapsible": false,
  "pages": ["index", "installation", "quick-start"]
}
  • title is the label of the folder in the sidebar.
  • pages sets the order. Pages that are not listed are appended at the end.
  • collapsible: false renders the folder as a category label instead of a collapsible group, which is how the top-level sections are built.
  • "---Label---" inside pages inserts a separator label without a folder.

Add the page file, then list it in the meta.json of its folder to control where it appears.

Deployment

.github/workflows/pages.yml builds both apps and deploys a single GitHub Pages site: the playground at the root and the docs under /docs. A Pages deployment replaces the whole site, so both apps have to build in the same workflow.

The docs build reads DOCS_BASE_PATH for that subpath. Without it the build targets the site root, which is what pnpm dev:docs and a local pnpm --filter @inksane/docs build use.

DOCS_BASE_PATH=/inksane/docs pnpm --filter @inksane/docs build

Links written in Markdown are not rewritten by Astro when a base path is set, so plugins/rehype-base-links.mjs prefixes root-relative links and image sources with it.

Checks in CI

Every pull request runs:

pnpm --filter @inksane/docs run sync
pnpm exec vp check
pnpm exec vp run -r test

vp check formats, lints, and type checks the repository. astro sync runs first because it generates the Astro content types for apps/docs. Without them the docs app is checked against Astro’s any fallback instead of its real collections, which hides type errors and reports a redundant-type warning. Run it once after cloning if you work on the docs:

pnpm --filter @inksane/docs run sync

Run pnpm exec vp check --fix to apply the formatting.