ryanflorence / react-router-relative-links

MIT License
78 stars 10 forks source link

use react-router-route-props-context package for middleware #4

Open jedwards1211 opened 8 years ago

jedwards1211 commented 8 years ago

instead of useRelativeLinks().

It's always seemed to me that there are a million potential use cases that would benefit from having props for the current route on context. I think it would be much cleaner if they all got them from a standard place provided by a single package than having every package like this use its own middleware to put the same route props in a separate place on the context.

Note I couldn't get ESLint to work on my machine with the versions/config in this package, but I did run the tests without linting and they passed.