feat: expose layouts and pages on App#3086
Merged
marvinhagemeister merged 2 commits intomainfrom Jul 14, 2025
Merged
Conversation
469e84c to
0ef308c
Compare
This was referenced Jul 14, 2025
marvinhagemeister
added a commit
that referenced
this pull request
Jul 14, 2025
82f8261 to
27f9487
Compare
This exposes the functionality previously hidden behind the `fs_routes` plugin for everyone. It's now part of the core Fresh API.
27f9487 to
e4bb03a
Compare
This was referenced Jul 14, 2025
marvinhagemeister
added a commit
that referenced
this pull request
Jul 16, 2025
This is a regression introduced in #3086
marvinhagemeister
added a commit
that referenced
this pull request
Jul 16, 2025
This is a regression introduced in #3086
marvinhagemeister
added a commit
that referenced
this pull request
Jul 16, 2025
This is a regression introduced in #3086
marvinhagemeister
added a commit
that referenced
this pull request
Jul 17, 2025
Fixes some regressions found after merging #3086 - Missing 404 middlewares when mounting sub-apps - revert more staticFiles logic to always require the middleware like before
This was referenced Jul 18, 2025
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.
This PR extracts the functionality from the
fs_routesplugin and exposes it ontoApp. These are the new APIs:app.layout(pattern, route)app.onError(pattern, route)app.notFound(pattern, route)app.route(pattern, route)This also removes the need for
.use(staticFiles()). This line can be safely removed.Fixes #3040
Fixes #3033
Fixes #2591
Fixes #950
Fixes #1918