Repository navigation
Serve the browser in dev as it ships; one build; frontend docs - #151
Merged
Merged
Conversation
#150 added e2e/browser (specs, harness pages, 11 baseline PNGs), .dependency-cruiser.cjs and tsconfig.domain.json to the archive. They are development-only, as is the host e2e check already under e2e/.
vite.inertia.config.ts scoped the browser's stylesheet and rewrote its font URLs in the build only, so npm run dev put the browser's tokens on :root, its rules on the whole host page and its fonts on a path nothing serves. The scoping now runs in dev too, and dev points the fonts at resources/assets/fonts; devStylesheet.test.ts asks the dev server for the stylesheet in middleware mode and was proven red on the old config. The production bundle is byte-identical. build and build:prod write resources/views/prepaint.html before the bundle, so a UI change is one build; build:prepaint still works alone. committed-build compares the prepaint view with public/assets.
A docs/recipes page covers the dev server with hot reload, every check, the Playwright suite and its baselines, and the one build. architecture.md, release.md, getting-started.md and the README index point at it and describe the e2e harness and layering guards.
There was a problem hiding this comment.
Copilot was unable to review this pull request because the user who requested the review has insufficient remaining quota. Try requesting a review at a lower effort level.
An organization owner can choose the repository organization as the billing source for reviews requested by members with a paid Copilot license. Learn about Copilot code review billing.
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.
Summary
React consolidation rows 4.1, 4.2 and 3.2 for the browser.
npm run devplusICHAVA_VITE_DEValready loadedresources/js/app.tsxfrom Vite with React Fast Refresh, butvite.inertia.config.tsscoped the browser's stylesheet and rewrote its font URLs in the build only. In dev the browser's tokens sat on:root, its rules reached the whole host page, and its fonts asked for/fonts/..., which nothing serves. The scoping now runs in dev too and dev points the fonts atresources/assets/fonts.devStylesheet.test.tsasks the dev server for the stylesheet in middleware mode (no port) and checks all three; proven red on the old config (3 of 4 fail). The production bundle is byte-identical.buildandbuild:prodwriteresources/views/prepaint.htmlbefore the bundle;build:prepaintstill works alone.committed-build.ymlcompares the prepaint view as well aspublic/assets(a drifted view is rewritten bybuild:prod, checked locally)./e2e,/.dependency-cruiser.cjsand/tsconfig.domain.jsonare export-ignored: Port react-icon-browser's CI, e2e suite and guards #150 had grown the Composer archive from 487 to 529 files; it is 484 now (the host e2e spec and its config, also dev-only, left with it).docs/recipes/frontend-development.md(dev server, checks, e2e, baselines, the one build, and theichava.scssglobal-scan trap).architecture.md,release.md,getting-started.mdand the README index updated.main(run 43510961891, dispatched: guards, e2e and visual all success). The one re-seed allowed for this PR ran on this branch inmcr.microsoft.com/playwright:v1.65.0-noble(visual-baselines.yml,commit: true, run 43512327848): the drift measurement passed 12 of 12, it regenerated them, and it reported changed baselines: 0, "Baselines already match; nothing to commit." So no PNG changed and there is no drift table to post: every one of the 12 baselines react-icon-browser committed is pixel-identical to the browser built fromresources/js.e2e/browser/visual.spec.ts-snapshotse2e/browser/svg-baseline.spec.ts-snapshotsNo deprecations:
build:prepaintkeeps working.Verification
vitest run136 files, 998 passed, 3 skipped.typecheck:inertia,lint,check:dead-links(incl. the new recipe): exit 0.build:prod:public/assetsunchanged. actionlint: clean.git archive HEAD: 484 files, none undere2e/or the two configs.