Skip to content

feat(playground): show the ODC version in the actions menu - #1520

Merged
joshunrau merged 2 commits into
mainfrom
feat/playground-version
Sep 1, 2026
Merged

feat(playground): show the ODC version in the actions menu#1520
joshunrau merged 2 commits into
mainfrom
feat/playground-version

Conversation

@thomasbeaudry

Copy link
Copy Markdown
Collaborator

Adds the ODC version to the bottom of the playground's ... menu, under a separator.

GitHub / Login / Upload Bundle / User Settings / Storage Usage
Delete Instrument / Restore Defaults
─────────────────
ODC Version 2.2.3

How the version gets there

Read from the root package.json in vite.config.ts and supplied as __APP_VERSION__, alongside the existing __GITHUB_REPO_URL__ define.

Not the __RELEASE__ define apps/web uses: @opendatacapture/release-info pulls in @opendatacapture/schemas, which ships raw TypeScript, so importing it here fails to load the config unless the playground's dev and build scripts run Vite under NODE_OPTIONS='--import=tsx' the way apps/web does. Reading the file directly avoids changing how this app builds and adds no dependency.

Tests

None. The playground has no vitest.config.ts, and testing/'s Playwright config only starts api, gateway and web — so there is no harness this could hook into without adding a webServer entry for an app that downloads an 11 MB wasm on boot.

Verified by hand instead: loaded the dev server, opened the menu, confirmed ODC Version 2.2.3 renders with no page errors.

🤖 Generated with Claude Code

Adds the monorepo version to the bottom of the "..." menu, below a
separator.

The version is read from the root package.json in vite.config.ts and
supplied as __APP_VERSION__, rather than through the __RELEASE__ define
apps/web uses: @opendatacapture/release-info pulls in
@opendatacapture/schemas, which ships raw TypeScript, so loading it here
would mean running this config under tsx as apps/web does.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
@thomasbeaudry

Copy link
Copy Markdown
Collaborator Author
image

@joshunrau
joshunrau merged commit cc69f80 into main Sep 1, 2026
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants