Skip to content

Compare running servers with --routes - #4

Merged
DorskFR merged 1 commit into
mainfrom
routes
Nov 12, 2026
Merged

DorskFR merged 1 commit into
mainfrom
routes

Conversation

@DorskFR

@DorskFR DorskFR commented Nov 12, 2026

Copy link
Copy Markdown
Owner

Server-rendered sites (Next.js getServerSideProps, Remix, Rails) have no HTML on disk. This lets cssdiff compare two running production servers:

cssdiff --routes /,/pricing http://localhost:3001 http://localhost:3002
  • --routes takes /path values or files listing one route per line.
  • Pages, <link> stylesheets and @imports are fetched over plain http:// (ureq without TLS, so the static release builds gain no C dependency). https:// is rejected with a clear error.
  • An HTTP status change between the two servers is reported as a difference; an unreachable server exits 2.
  • --timeout bounds each request (default 30 s).

Verified: fmt, clippy -D warnings, 25 tests (4 new, against an in-test HTTP server). A 28-page site served over HTTP gives exactly the same 1233 changes as the directory compare of the same builds.

🤖 Generated with Claude Code

Two http:// arguments fetch the given routes from both servers, with
their stylesheets, so server-rendered sites can be compared without a
static build. An HTTP status change is reported as a difference.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@DorskFR
DorskFR merged commit ca1fc84 into main Nov 12, 2026
1 check passed
@DorskFR
DorskFR deleted the routes branch November 12, 2026 11:30
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