WORK-461
ID:WORK-461Status:ready

kind-keyed install apply with framework-aware and compat validation

SPEC-110 §4–§5 + ADR-023/ADR-024 — unify the apply step over the shared resolver, keyed on artifact + manifest kind, and harden post-install validation (framework-aware + compat-range).

Priority:highComplexity:moderateMilestone:v0.25.0Source:SPEC-110
claude/v0.25.0-workitems View source

Criteria completion

Criteria completion: 0 of 4 (0%) checked; tracking started on Jun 23, no incremental history yet0%25%50%75%100%Jun 23Jul 11

Tracking started Jun 23 — check back for trends.

Branches 4
History 2
  1. c36d24c
    Content editedby bjornolofandersson
  2. a6bdcba
    Created (ready)by bjornolofandersson

Acceptance Criteria

  • Install applies a kind-keyed step over the shared resolver: theme → dependency + point the selected site's theme; kind:"site" template → add a site; preset pack → dependency + validate + optional presets.json append
  • kind:"section" is reserved/forward-compatible (reuses the resolver, SiteConfig merge, and --site plumbing) but out of scope
  • Post-install validation covers a theme's exports and a template's template.json; theme validation is framework-aware per ADR-024 (./transform required, a framework export like ./svelte optional — its absence is not warned)
  • Install validates each distributable's refrakt range against the project version, failing with a clear message on mismatch

Approach

Factor the apply step as a switch on artifact/kind in packages/cli/src/commands/theme.ts (rename/extend toward a general install command). Replace the current "./svelte missing → warn" check with the framework-aware rule. Call the ADR-023 compat checker before applying. The theme, template, and preset apply-modes are implemented in their respective work items; this item owns the dispatch + validation layer.

Dependencies

  • WORK-465 — compat range checker
  • WORK-445 — shared resolver
  • WORK-446 — multi-site --site + config helpers

References

  • SPEC-110 §4, §5; ADR-023; ADR-024