Extract slug-federation npm package #246

Merged
erik merged 1 commit from feat/task-982e97df-slug-federation-package into main 2026-06-29 21:44:39 -05:00
Owner

Summary

  • Add @evcraddock/slug-federation workspace package with stable ActivityPub helpers for runtime config, actor URLs/input validation, remote URL safety, actor display/handle reading, key import/sender helpers, and outbox HTML/URL helpers.
  • Update template federation modules to consume package exports while preserving local wrappers for database persistence, private key ownership, domain config, delivery wiring, route composition, and operational decisions.
  • Add generated-site dependency mapping for @evcraddock/slug-federation@0.1.0 because federation remains in the default template.
  • Add @evcraddock/slug-federation to the Forgejo npm package release workflow choices.
  • Document package exports, local federation ownership boundaries, and key/domain safety upgrade notes.

Verification

  • npm run build --workspace @evcraddock/slug-federation
  • npm run typecheck --workspaces
  • npm test --workspace @evcraddock/slug-federation
  • npm test --workspace @slugkit/template-site -- src/federation
  • npm test --workspace @evcraddock/slug-cli -- commands.test.ts
  • npm run package:pack:dry-run -- --workspace @evcraddock/slug-federation
  • npm run package:release -- --workspace @evcraddock/slug-federation --dry-run
  • ./scripts/pre-pr.sh

Task: #task-982e97df

## Summary - Add `@evcraddock/slug-federation` workspace package with stable ActivityPub helpers for runtime config, actor URLs/input validation, remote URL safety, actor display/handle reading, key import/sender helpers, and outbox HTML/URL helpers. - Update template federation modules to consume package exports while preserving local wrappers for database persistence, private key ownership, domain config, delivery wiring, route composition, and operational decisions. - Add generated-site dependency mapping for `@evcraddock/slug-federation@0.1.0` because federation remains in the default template. - Add `@evcraddock/slug-federation` to the Forgejo npm package release workflow choices. - Document package exports, local federation ownership boundaries, and key/domain safety upgrade notes. ## Verification - `npm run build --workspace @evcraddock/slug-federation` - `npm run typecheck --workspaces` - `npm test --workspace @evcraddock/slug-federation` - `npm test --workspace @slugkit/template-site -- src/federation` - `npm test --workspace @evcraddock/slug-cli -- commands.test.ts` - `npm run package:pack:dry-run -- --workspace @evcraddock/slug-federation` - `npm run package:release -- --workspace @evcraddock/slug-federation --dry-run` - `./scripts/pre-pr.sh` Task: #task-982e97df
feat: extract slug federation package
All checks were successful
CI / build-lint-test (pull_request) Successful in 57s
123841c27d
Task: #task-982e97df
Author
Owner

Review summary

PR #246 extracts stable ActivityPub helper seams into @evcraddock/slug-federation while keeping generated-site ownership of domain configuration, persistence, private keys, delivery wiring, route composition, and operational decisions in local federation modules.

Acceptance criteria

  • @evcraddock/slug-federation exists as a workspace package — packages/slug-federation includes package metadata, TS configs, README, public exports, and tests.
  • Template site consumes @evcraddock/slug-federation through the local workspace link because federation remains in the default template — template/site/package.json declares @evcraddock/slug-federation: 0.1.0, which npm links locally in the workspace.
  • Template-site federation behavior remains unchanged — existing federation tests pass, along with full pre-PR/CI.
  • Generated sites created after release depend on the published package when federation is included — generated-site dependency mapping now includes @evcraddock/slug-federation@0.1.0.
  • Local wrappers preserve domain, key, storage, and delivery customization points — template federation modules remain in template/site/src/federation/*, and the README documents local ownership boundaries.
  • Public exports are documented and tested — package README documents exports; package tests cover runtime config, actor helpers, URL safety, key helpers, and outbox helpers.
  • Package is published and post-publish install/import verification succeeds — not applicable until after this implementation PR is merged; this PR adds the release workflow choice needed to publish.
  • ./scripts/pre-pr.sh passes — verified locally and Forgejo CI run #352 passed.

Blocking issues

None for merging this implementation PR.

Warnings

  • Post-merge release still required: dispatch the Forgejo npm package release workflow for @evcraddock/slug-federation and verify install/import before closing the task.

Verdict

Approved. Stop at the human merge gate.

### Review summary PR #246 extracts stable ActivityPub helper seams into `@evcraddock/slug-federation` while keeping generated-site ownership of domain configuration, persistence, private keys, delivery wiring, route composition, and operational decisions in local federation modules. ### Acceptance criteria - [x] `@evcraddock/slug-federation` exists as a workspace package — `packages/slug-federation` includes package metadata, TS configs, README, public exports, and tests. - [x] Template site consumes `@evcraddock/slug-federation` through the local workspace link because federation remains in the default template — `template/site/package.json` declares `@evcraddock/slug-federation: 0.1.0`, which npm links locally in the workspace. - [x] Template-site federation behavior remains unchanged — existing federation tests pass, along with full pre-PR/CI. - [x] Generated sites created after release depend on the published package when federation is included — generated-site dependency mapping now includes `@evcraddock/slug-federation@0.1.0`. - [x] Local wrappers preserve domain, key, storage, and delivery customization points — template federation modules remain in `template/site/src/federation/*`, and the README documents local ownership boundaries. - [x] Public exports are documented and tested — package README documents exports; package tests cover runtime config, actor helpers, URL safety, key helpers, and outbox helpers. - [ ] Package is published and post-publish install/import verification succeeds — not applicable until after this implementation PR is merged; this PR adds the release workflow choice needed to publish. - [x] `./scripts/pre-pr.sh` passes — verified locally and Forgejo CI run #352 passed. ### Blocking issues None for merging this implementation PR. ### Warnings - Post-merge release still required: dispatch the Forgejo npm package release workflow for `@evcraddock/slug-federation` and verify install/import before closing the task. ### Verdict Approved. Stop at the human merge gate.
erik merged commit a09d46669a into main 2026-06-29 21:44:39 -05:00
erik deleted branch feat/task-982e97df-slug-federation-package 2026-06-29 21:44:39 -05:00
Sign in to join this conversation.
No reviewers
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
erik/slugkit!246
No description provided.