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

fix(gatsby): use history fallback to display client-only routes in serve #11581

Merged
merged 1 commit into from
Feb 6, 2019

Conversation

DSchau
Copy link
Contributor

@DSchau DSchau commented Feb 5, 2019

Description

As best as I can tell--this fixes a few issues identified with
client-only routes, without causing a regression in existing
functionality.

What I validated:

  • Client only routes work (and work on initial navigation, e.g. given
    dynamic path /app/1234, it works when navigated to and on initial route)
  • Existing routes created via SSR work
  • 404 routes work (and direct 404.html route)
    • implicit 404, e.g. /asdfasdfasdf loads 404 page
    • explicit 404, e.g. /404 loads 404 page

cc @jquense

Related Issues

Fixes #8080

As best as I can tell--this fixes a few issues identified with
client-only routes, without causing a regression in existing
functionality.

What I validated:

- Client only routes work (and work on initial navigation, e.g. given
dynamic path /app/1234, it works when navigated to and on initial route)
- Existing routes created via SSR work
- 404 routes work (and direct 404.html route)

Fixes gatsbyjs#8080
@DSchau DSchau requested a review from a team as a code owner February 5, 2019 23:26
@DSchau
Copy link
Contributor Author

DSchau commented Feb 6, 2019

Checking out the failing production runtime test!

@DSchau
Copy link
Contributor Author

DSchau commented Feb 6, 2019

The tests pass locally - must be some CI weirdness :/ I'll check this out in a bit, and try to fix the flaky gatsby-image test too.

@DSchau DSchau merged commit 75f6118 into gatsbyjs:master Feb 6, 2019
@DSchau DSchau deleted the gatsby/history-fallback branch February 6, 2019 16:10
DSchau added a commit to DSchau/gatsby that referenced this pull request Feb 6, 2019
DSchau added a commit to DSchau/gatsby that referenced this pull request Feb 7, 2019
wardpeet pushed a commit that referenced this pull request Feb 11, 2019
* Revert "fix(gatsby): use history fallback to display client-only routes in serve (#11581)"

This reverts commit 75f6118.

* Revert "fix(gatsby): use history fallback to display client-only routes in serve (#11581)"

This reverts commit 75f6118.

* fix: use smart history fallback that understands gatsby matchPath

* chore: fix

* refactor: swap to reach router instead of micromatch

* chore: move check up

* chore: tweak name
gurpreet-hanjra pushed a commit to gurpreet-hanjra/gatsby that referenced this pull request Feb 14, 2019
)

* Revert "fix(gatsby): use history fallback to display client-only routes in serve (gatsbyjs#11581)"

This reverts commit 75f6118.

* Revert "fix(gatsby): use history fallback to display client-only routes in serve (gatsbyjs#11581)"

This reverts commit 75f6118.

* fix: use smart history fallback that understands gatsby matchPath

* chore: fix

* refactor: swap to reach router instead of micromatch

* chore: move check up

* chore: tweak name
pragmaticpat pushed a commit to pragmaticpat/gatsby that referenced this pull request Apr 28, 2022
)

* Revert "fix(gatsby): use history fallback to display client-only routes in serve (gatsbyjs#11581)"

This reverts commit 75f6118.

* Revert "fix(gatsby): use history fallback to display client-only routes in serve (gatsbyjs#11581)"

This reverts commit 75f6118.

* fix: use smart history fallback that understands gatsby matchPath

* chore: fix

* refactor: swap to reach router instead of micromatch

* chore: move check up

* chore: tweak name
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.

[v2] gatsby servebugs
2 participants