Skip to content

Add SolidStart integration and refactor fedify init internals#652

Open
2chanhaeng wants to merge 24 commits intofedify-dev:mainfrom
2chanhaeng:main
Open

Add SolidStart integration and refactor fedify init internals#652
2chanhaeng wants to merge 24 commits intofedify-dev:mainfrom
2chanhaeng:main

Conversation

@2chanhaeng
Copy link
Copy Markdown
Contributor

Summary

Add @fedify/solidstart package for SolidStart integration and overhaul
fedify init internals: centralize dependency versions, replace
runSubCommand with @david/dax, and improve test infrastructure.

Related issue

Changes

  • packages/solidstart: Add packages/solidstart/ providing fedifyMiddleware() for SolidStart's middleware system. (by @dodok8)
  • packages/init:
    • Add SolidStart web framework option. (by @dodok8)
    • Extract hardcoded third-party dependency versions and add scripts/update_init_deps.ts to auto-update dependency versions.
    • Refactor code like replacing runSubCommand with @david/dax.
    • Use port 0 binding from 10000 while mise test:init.
    • Print skipped and failed cases with reasons and directories.
  • packages/express: Fix bug by replacing req.host with req.header("Host").
  • packages/astro: Fix bug by adding --no-install for non-Deno package managers.
  • docs: Add docs about SolidStart integration. (by @dodok8)
  • examples/solidstart: Add an example app using SolidStart integration. (by @dodok8)

Benefits

  • SolidStart users can integrate Fedify with a single middleware call. (by @dodok8)
  • Dependency versions for fedify init templates are now centralized
    and auto-updatable, reducing manual maintenance.
  • Replacing runSubCommand with @david/dax simplifies subprocess
    handling and removes custom error classes.
  • Dynamic port allocation in tests eliminates port conflicts when
    running multiple test apps sequentially.

Additional notes

@issues-auto-labeler issues-auto-labeler bot added component/build Build system and packaging component/cli CLI tools related component/federation Federation object related component/integration Web framework integration labels Mar 28, 2026
Copy link
Copy Markdown
Contributor

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request introduces the @fedify/solidstart package for SolidStart integration, providing a new middleware, comprehensive documentation, and an example project. Significant refactoring was performed on the @fedify/init package to centralize dependency versions in JSON files and migrate command execution to the dax library. Feedback highlights the need to update CHANGES.md with missing bug fixes and proper contributor credit, ensure consistency in middleware implementation examples, and move hardcoded dependency versions in the new SolidStart integration logic to the centralized configuration.

@codecov
Copy link
Copy Markdown

codecov bot commented Mar 28, 2026

Codecov Report

❌ Patch coverage is 15.41426% with 439 lines in your changes missing coverage. Please review.
✅ All tests successful. No failed tests found.

Files with missing lines Patch % Lines
packages/init/src/test/server.ts 3.65% 158 Missing ⚠️
packages/init/src/test/port.ts 11.53% 92 Missing ⚠️
packages/init/src/webframeworks/solidstart.ts 12.90% 81 Missing ⚠️
packages/init/src/test/lookup.ts 32.94% 57 Missing ⚠️
packages/init/src/action/utils.ts 40.00% 12 Missing ⚠️
packages/init/src/webframeworks/hono.ts 8.33% 11 Missing ⚠️
packages/init/src/webframeworks/elysia.ts 9.09% 10 Missing ⚠️
packages/init/src/webframeworks/astro.ts 10.00% 9 Missing ⚠️
packages/init/src/webframeworks/express.ts 12.50% 7 Missing ⚠️
packages/init/src/lib.ts 75.00% 1 Missing ⚠️
... and 1 more
Files with missing lines Coverage Δ
packages/init/src/const.ts 100.00% <100.00%> (ø)
packages/init/src/webframeworks/const.ts 100.00% <100.00%> (ø)
packages/init/src/webframeworks/mod.ts 100.00% <100.00%> (ø)
packages/init/src/lib.ts 48.38% <75.00%> (ø)
packages/init/src/webframeworks/next.ts 23.40% <50.00%> (ø)
packages/init/src/webframeworks/express.ts 16.92% <12.50%> (ø)
packages/init/src/webframeworks/astro.ts 12.79% <10.00%> (ø)
packages/init/src/webframeworks/elysia.ts 13.41% <9.09%> (ø)
packages/init/src/webframeworks/hono.ts 15.85% <8.33%> (ø)
packages/init/src/action/utils.ts 54.71% <40.00%> (-8.92%) ⬇️
... and 4 more

... and 4 files with indirect coverage changes

🚀 New features to boost your workflow:
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

2chanhaeng and others added 23 commits March 29, 2026 01:10
Extract the Fedify middleware for SolidStart into a dedicated package
(@fedify/solidstart), providing a fedifyMiddleware() helper that handles
ActivityPub content negotiation with SolidStart's middleware system.

Uses a WeakMap<Request, Response> internally for 406 response storage,
so users don't need to declare App.RequestEventLocals.

Update the example to use the new package instead of inline middleware.

fedify-dev#476

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Add a SolidStart section to docs/manual/integration.md with installation
instructions, app.config.ts setup, and middleware usage example.

Add @fedify/solidstart changelog entry under Version 2.1.0, and update
packages/fedify/README.md with JSR link for the new package.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Add SolidStart as a web framework option in the `fedify init` command,
allowing users to scaffold new Fedify+SolidStart projects.  All
boilerplate files (app config, middleware, routes, entry points) are
provided as templates since no suitable degit template exists for
SolidStart.

The lookup test skips the solidstart+deno combination because Deno's
`links` feature does not populate `node_modules/`, which Vite (used by
vinxi) requires for SSR module resolution.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Deno import maps use exact string matching, so the base
"@solidjs/start" entry does not resolve subpath specifiers like
"@solidjs/start/config" or "@solidjs/start/server".  This adds
explicit mappings for all subpaths used by the generated template
files and @fedify/solidstart.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Consolidate lookup-test-only exclusions into a single pattern-based rule table so framework-wide and combination-specific bans follow the same matching logic. This keeps the supported-option checks unchanged while making the temporary lookup exclusions easier to maintain.

Add regression tests for lookup case parsing and wildcard-based filtering.

Co-Authored-By: OpenAI Codex <noreply@openai.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

component/build Build system and packaging component/cli CLI tools related component/federation Federation object related component/integration Web framework integration

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Auto update fedify init dependency versions Assign random port number while test-init

2 participants