Skip to content
This repository was archived by the owner on May 25, 2021. It is now read-only.
This repository was archived by the owner on May 25, 2021. It is now read-only.

Bug in the future: routing implementation not compatible with react-router 5.1.2 #294

@michaud

Description

@michaud

Describe the bug
when the page loads and the user is not logged in, the page loads to /welcome and gives an error message 'Something went wrong', and throws an error: Uncaught Invariant Violation: You should not use outside a

To Reproduce
Steps to reproduce the behavior:

  1. npm install react-router-dom@5.1.2
  2. npm start
  3. See error

Expected behavior
/welcome should redirect to /login and show the login page

Desktop (please complete the following information):

  • OS: Windows 10
  • Browser Chrome
  • Version 79.0.3945.130 (Official Build) (64-bit)

Additional context
After some investigation i've narrowed it down to Private Layout loosing the context of the Router but I can't find futher avenues of investigation because the error occurse in the validation code of react-router. this is the callstack:

in jl (created by t)
in t (created by WithWebId(t))
in WithWebId(t) (at routes.js:87)
in Switch (at routes.js:81)

line 87 is the Private Layout component

Metadata

Metadata

Assignees

No one assigned

    Labels

    TriagedIssue has been triaged and prioritized by the development team.bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions