insin / insin/react-router-active-component

Warning: "Unknown props `active`, `activeKey`, `activeHref"

Open
#7 5 comments 0 reactions 0 assignees View on GitHub
Dominant language
JavaScript
Stars
112
Forks
23
PR merge metrics
No merged PRs in 30d

Description

I am getting the following annoying warnings in the browser console:

> warning.js:19 Warning: Unknown props `active`, `activeKey`, `activeHref` on < li> tag. Remove these props from the element. For details, see https://fb.me/react-unknown-prop
> in li (created by ActiveComponent)
> in ActiveComponent (created by withRouter(ActiveComponent))
> in withRouter(ActiveComponent) (created by MainLayout)
> in ul (created by Nav)
> in Nav (created by MainLayout)
> in div (created by NavbarCollapse)
> in Transition (created by Collapse)
> in Collapse (created by NavbarCollapse)
> in NavbarCollapse (created by MainLayout)
> in div (created by Grid)
> in Grid (created by Navbar)
> in nav (created by Navbar)
> in Navbar (created by Uncontrolled(Navbar))
> in Uncontrolled(Navbar) (created by MainLayout)
> in div (created by MainLayout)
> in MainLayout (created by RouterContext)
> in RouterContext (created by Router)
> in Router (created by App)
> in App

According to https://github.com/react-bootstrap/react-bootstrap/issues/1994, react-router-active-component should filter out irrelevant props coming from parent components. Unless the culprit is `react-router`?

On another note, it would be good if you could publish the typings to allow easy usage with TypeScript.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.