STRML / react-router-component

Declarative router component for React.
http://strml.viewdocs.io/react-router-component
MIT License
874 stars 94 forks source link

Support filtering named segments #191

Closed jsg2021 closed 7 years ago

jsg2021 commented 7 years ago

...so that route handlers get the decoded value(s)

To do so, pass a urlPatternOptions object with a property of namedSegmentValueDecoders. This property can be either: 1) function (name, value) => value 2) object with {name: function(value) => value, ...}

This provides the functionality described in #189

STRML commented 7 years ago

This seems good - could you add changes to the necessary docs?

jsg2021 commented 7 years ago

Sure, which docs would you suggest? overriding url pattern options?

STRML commented 7 years ago

Yeah, https://github.com/STRML/react-router-component/blob/master/docs/override-url-pattern.md

jsg2021 commented 7 years ago

I think the issues have been addressed :)

STRML commented 7 years ago

Yep, looks good. Thanks!

STRML commented 7 years ago

0.36.4