Repository navigation
feat(cli): export themeTemplate from public API - #6702
Closed
josephfarina wants to merge 1 commit into
Closed
josephfarina wants to merge 1 commit into
josephfarina wants to merge 1 commit into
Conversation
The CLI command and docs already use themeTemplate(), but the public API entry point does not export it. Export it and cover the runtime and packed type surfaces.
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Contributor
|
AI review status for this pull request.
|
Contributor
PR Analysis Report
No new or modified components detected. Bundle Size SummaryNo component packages changed. Accessibility AuditStatus: No accessibility violations detected. Visual RegressionStatus: No visual change across 420 compared shot(s). Generated by PR Enrichment workflow | View full report |
3 tasks done
josephfarina
added a commit
that referenced
this pull request
Sep 28, 2026
Folded in from #6702. Exports themeTemplate from @astryxdesign/cli/api with runtime and packed-type guards, and removes the resolved known-gap bullet from AST-042.
Contributor
Author
|
Folded into #6626, so there is one PR to review, approve, and merge. The commit is there unchanged, on current main, and |
josephfarina
added a commit
that referenced
this pull request
Sep 28, 2026
Folded in from #6702. Exports themeTemplate from @astryxdesign/cli/api with runtime and packed-type guards, and removes the resolved known-gap bullet from AST-042.
josephfarina
added a commit
that referenced
this pull request
Sep 28, 2026
…emeTemplate export One change on main after #6695: the docs tree for the CLI and integrations (AST-046), navigable reads with typed links (AST-047), integration templates that replace Core templates (AST-035, from #6265), and the themeTemplate export (from #6702). JSON keeps its 0.6 shapes; the CLI's text reads one level at a time.
josephfarina
added a commit
that referenced
this pull request
Sep 28, 2026
…emeTemplate export One change on main after #6695: the docs tree for the CLI and integrations (AST-046), navigable reads with typed links (AST-047), integration templates that replace Core templates (AST-035, from #6265), and the themeTemplate export (from #6702). JSON keeps its 0.6 shapes; the CLI's text reads one level at a time.
This branch was successfully deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
User need
Automation that can run
astryx theme templateneeds the same operation through the supported programmatic API. The function and its docs already exist, but importing it from@astryxdesign/cli/apifails because the entry point doesn't export it.Problem and solution fit
The theme barrel exports
themeTemplate(), while the public API barrel skips it. I added that missing re-export, a direct public-entry regression test, and coverage in the packed consumer type check. I also removed the resolved gap from AST-042.Current specification
AST-042 FR1 requires each operational command to call a function exported from
@astryxdesign/cli/api.Public delta and caller burden
Before:
After:
This is additive. The function's inputs, defaults, result, errors, and CLI behavior don't change. Callers make no new decisions.
Design and alternatives
A deep import would bypass the package's supported export surface. A second function would duplicate the operation. The existing documented function is the owner, so the public barrel should export it.
Evidence
@astryxdesign/cli/apias the import path.theme templatecommand already callsthemeTemplate().Dependency with #6617
If #6617 merges first, this PR must delete its FR1 allowlist entry for
themeTemplate. If this merges first, #6617's stale-entry check fails until that row is removed.Scope
Testing
pnpm exec vitest run packages/cli/api/theme/template/template.test.mjs packages/cli/foundation/discovery/cli-self-docs.test.mjs(22 passed)pnpm exec vitest run packages/cli(5,134 passed, 2 expected failures)node .github/scripts/cli-api-types-verify.mjspnpm check:repopnpm --filter @astryxdesign/theme-neutral build && pnpm --filter @astryxdesign/cli typecheck:strictpnpm --filter @astryxdesign/cli typecheck:json-apipnpm --filter @astryxdesign/cli readme:check