Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feat: show 404 when getStaticPaths doesn't match URL #2743

Merged
merged 22 commits into from
Mar 10, 2022
Merged
Changes from 1 commit
Commits
Show all changes
22 commits
Select commit Hold shift + click to select a range
9a16d91
WIP: return 404 for unmatched getStaticPaths route
Mar 8, 2022
18adf0e
feat: regex on static paths to 404 in dev
bholmesdev Mar 9, 2022
93e23f1
Revert "WIP: return 404 for unmatched getStaticPaths route"
bholmesdev Mar 9, 2022
66b0a86
feat: call getParamsAndProps pre-ssr to catch errs
bholmesdev Mar 9, 2022
016def8
fix: remove unused cache regex check
bholmesdev Mar 9, 2022
56c1ce2
fix: revert getPattern changes
bholmesdev Mar 9, 2022
d4716fa
fix: remove unused preload props
bholmesdev Mar 9, 2022
eddfa31
fix: log 404 for custom 404 pages
bholmesdev Mar 9, 2022
7b35dd9
refactor: rename fixture for clarity
bholmesdev Mar 9, 2022
76dd486
feat: add getStaticPaths status code tests
bholmesdev Mar 9, 2022
24a5d13
fix: pas rootRelativeUrl to handle subpaths
bholmesdev Mar 9, 2022
120c323
fix: update dev-routing tests from 500 -> 404
bholmesdev Mar 9, 2022
3b3ccc9
refactor: make error handling more explicit
bholmesdev Mar 9, 2022
678ed2a
lint: use typescript no shadow to fix enum issue
bholmesdev Mar 9, 2022
e7df851
chore: add changeset
bholmesdev Mar 9, 2022
384e373
refactor: clarify test names
bholmesdev Mar 9, 2022
d1a5716
refactor: remove variable reassignment
bholmesdev Mar 9, 2022
693d60b
fix: update dev-routing tests 500 > 404
bholmesdev Mar 10, 2022
d6cdb5f
refactor: update test file structure
bholmesdev Mar 10, 2022
42229e6
Fix: revert to old logging
bholmesdev Mar 10, 2022
bf63126
Chore: use `const enum` instead
bholmesdev Mar 10, 2022
951ec46
chore: format
bholmesdev Mar 10, 2022
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Chore: use const enum instead
Co-authored-by: Nate Moore <[email protected]>
  • Loading branch information
bholmesdev and natemoo-re committed Mar 10, 2022
commit bf63126808afd5a9f83e3ef7fdfb189752475f0f
2 changes: 1 addition & 1 deletion packages/astro/src/core/render/core.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ interface GetParamsAndPropsOptions {
logging: LogOptions;
}

export enum GetParamsAndPropsError {
export const enum GetParamsAndPropsError {
NoMatchingStaticPath,
}

Expand Down