Skip to content

Allow tokenless installs and align Storybook on 10.x - #5

Merged
StanBarrows merged 1 commit into
mainfrom
feat/tokenless-git-install
Jul 30, 2026
Merged

Allow tokenless installs and align Storybook on 10.x#5
StanBarrows merged 1 commit into
mainfrom
feat/tokenless-git-install

Conversation

@StanBarrows

Copy link
Copy Markdown
Contributor

Why

Two independent problems, one of which makes the repo uninstallable.

npm ci fails on main. @storybook/vue3-vite is ^10.5.3 while storybook is ^9.0.0 and both addons are ^9.1.20. vue3-vite@10 requires peer storybook@^10, so the tree cannot resolve — and release, pages and test all start with npm ci. The lockfile still holds 9.1.20 for both, so that bump was never completed.

Consuming the package needs a GitHub token even though the repo is public. files is ["dist"] and dist is gitignored, so a git dependency resolves to a package with no entry point. That left GitHub Packages as the only route — and its npm registry requires a token for every read, public packages included.

What this changes

prepare: npm run build — makes the public repo directly consumable, no token:

"@codebar-ag/storybook": "github:codebar-ag/storybook.codebar.ch#v1.5.0"

It also means npm publish always ships a freshly built dist rather than whatever was last in the working tree.

publishConfig.accesspublic. Worth being precise: this only affects future publishes. The existing package's visibility is a setting on the package itself, and GitHub's npm registry needs a token regardless of visibility. The git dependency above is what actually removes the token requirement.

Storybook family → ^10.5.5. The abandoned ^10.5.3 bump was reaching for a real security fix, so this completes it rather than reverting to 9.x. It clears all five advisories — including the PostCSS source-map path traversal (#5) — by pulling vue-component-meta and @vue/language-core to versions whose minimatch/brace-expansion are patched. Reverting to 9.x would have restored npm ci but left every advisory in place.

npm audit: 0 vulnerabilities (was 5 high).

Two implicit-any annotations in Pagination.vue. Pre-existing and unrelated, but typecheck could not run while the tree was uninstallable, so nothing had reported them.

Verified locally

  • npm ci — now succeeds
  • npm audit — 0 vulnerabilities
  • npm run build, lint, typecheck — clean
  • npm run build-storybook — succeeds, no config migration needed for Storybook 10
  • npm run test:ci184 Playwright tests pass

Note for reviewers

The Storybook 9 → 10 major is the substantive change here. It is load-bearing for the security fix, not incidental, and the full docs build plus the whole smoke suite pass on it unchanged.

🤖 Generated with Claude Code

Adds `prepare` so the package can be consumed straight from this public
repository as a git dependency, with no GitHub Packages token:

    "@codebar-ag/storybook": "github:codebar-ag/storybook.codebar.ch#v1.5.0"

`files` is `["dist"]` and `dist` is gitignored, so a git install previously
resolved to a package with no entry point at all. `prepare` runs on git
installs and builds it, which is also why `npm publish` now always ships a
freshly built `dist` rather than whatever was last in the working tree.

`publishConfig.access` becomes `public`. Note this only affects future
publishes — the existing package's visibility is a setting on the package
itself, and GitHub's npm registry requires a token for every read regardless,
public or not. The git dependency above is what actually removes the token.

Fixes a dependency tree that could not be installed at all. `npm ci` failed on
main — and with it release, pages and test — because `@storybook/vue3-vite` was
`^10.5.3` while `storybook` stayed `^9.0.0` and both addons `^9.1.20`, so its
peer requirement of `storybook@^10` was unsatisfiable. That half-finished bump
was reaching for a real fix, so this completes it rather than reverting it:
aligning the family on `^10.5.5` clears all five advisories, including the
PostCSS source-map path traversal, by pulling vue-component-meta and
@vue/language-core to versions whose minimatch/brace-expansion are patched.
`npm audit` reports 0 vulnerabilities.

Annotates two implicit-any handler parameters in Pagination.vue. Pre-existing
and unrelated to the upgrade, but `typecheck` could not run while the tree was
uninstallable, so nothing had reported them.

Verified: npm ci, build, lint, typecheck, build-storybook and 184 Playwright
tests all pass, and Storybook 10 needed no config migration.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
@StanBarrows
StanBarrows merged commit 7d6836a into main Jul 30, 2026
2 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.

1 participant