question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Request for router docs/examples

See original GitHub issue

Is this a feature request?

I’m currently trying to upgrade to v6, and I’ve hit some snags with the router. The docs say v6 still uses react-router under the hood, and that I can require my own version to override the default. However, it looks like v6 is actually using a smidge of @reach/router, which has a noticeably different API.

I think it would be really useful to see a few things:

  1. Some description of the router-lite approach you took for v6 and why you’re recommending @reach/router going forward.
  2. An example using @reach/router, showing how to get react-router features in the new context. For example, withRouter.
  3. And another example that demos how to continue using react-router.

I’m going to plow ahead on this, but I suspect this sort of documentation would be helpful all around.

Thanks!

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:7 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
mikestopcontinuescommented, Dec 19, 2018

@farskid, I’d really like to see how you did your work, and I’d also be happy to contribute to the docs as well, once I get things running.

0reactions
tannerlinsleycommented, Jan 8, 2019

I think with the guides we have now and the updated docs, this can be closed.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Custom Bid Router Request and Response examples
MediaMath delivers bid opportunity requests to the configured Custom Bid Router endpoints over HTTPS. The content type for the body of the request...
Read more >
Express Tutorial Part 4: Routes and controllers - MDN Web Docs
The example routes above use the Router.get() method to respond to HTTP GET requests with a certain path. ... For example, the code...
Read more >
Express routing
Here are some examples of route paths based on strings. This route path will match requests to the root route, / . app.get('/',...
Read more >
berstend/tiny-request-router: Fast, generic and type safe ...
Features. Minimal and opinionless router, can be used in any script and environment. Matches a request method (e.g. GET ) and a path...
Read more >
How Requests are Routed | App Engine standard ...
For example, you can create a dispatch file to route mobile requests like https://simple-sample.uc.r.appspot.com/mobile/ to a mobile frontend, and route worker ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found