Skip to content
This repository has been archived by the owner on Nov 15, 2022. It is now read-only.

Minor - router.js:257 Uncaught wth #51

Open
bvalyou opened this issue May 3, 2019 · 0 comments
Open

Minor - router.js:257 Uncaught wth #51

bvalyou opened this issue May 3, 2019 · 0 comments

Comments

@bvalyou
Copy link

bvalyou commented May 3, 2019

There is one routing path in my application that hits the throw 'wth'; line that runs when stackEntry is falsy. Outside of my routing logic I render a navigation menu with <A href="/" />. There's only one page where clicking that link causes it to throw this error. It doesn't break anything, but I thought I'd mention it since it's kind of an interesting case. Also because it's just a beautiful error.

When it happens, I see

> JSON.stringify(stack, null, 2)
"{
  "1": {
    "routerId": 1,
    "originalRouteObj": {},
    "routes": [
      [
        "/",
        null
      ],
      [
        "/campaigns*",
        null
      ],
      [
        "/utilities*",
        null
      ],
      [
        "/characters*",
        null
      ]
    ],
    "parentRouterId": null,
    "matchedRoute": "/",
    "reducedPath": "",
    "passContext": false,
    "result": {
      "key": null,
      "ref": null,
      "props": {},
      "_owner": null,
      "_store": {}
    }
  }
}"
> parentRouterId
8
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant