infernojs / inferno

:fire: An extremely fast, React-like JavaScript library for building modern user interfaces

Home Page:https://infernojs.org

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Document inferno-router

Coachonko opened this issue · comments

Currently the website links to the react router documentation, third party documentation is not perfectly matching current inferno-router functionality (hooks missing, native support missing though mentioned), furthermore it may be taken down at any time since react-router v5 is old and soon unmaintained

It would be best to mirror the docs for now, edit and publish them on the Inferno website later.

Yeah thats true, was there something specific what you were looking for? Did you find the information? Is it something you could maybe add to the inferno router documentation?

Yeah thats true, was there something specific what you were looking for? Did you find the information? Is it something you could maybe add to the inferno router documentation?

The fact that the hooks are not implemented is not mentioned, not difficult to find out but I think all differences should be mentioned when referencing a third-party document. I think these small issues are hurting adoption, particularly now that Inferno is diverging from React more and more

The technique documented in react-router v5 to give specific classes to inactive NavLink does not seem to work, I'm seeking help in the discord to confirm whether it is the intended behavior or not first, but nobody has replied on discord yet.

<NavLink
  to="/faq"
  className={isActive =>
    "nav-link" + (!isActive ? " nounderline" : "")
  }
>
  FAQs
</NavLink>

results in

<a class="function className(isActive) {
      return &quot;nav-link&quot; + (!isActive ? &quot; no-underline&quot; : &quot;&quot;);
    }" aria-current="false" href="/faq">FAQs</a>