Franco
10/18/2021, 7:15 AMkotlin-wrappers
lib and I noticed that the React wrapper has changed quite a bit and now I'm not sure how to do the following:
route("${url}/:id") { props ->
val idParam = props.match.params.id
...
}
Does anyone know how to do this with the new API?
@turansky you might know 🙂turansky
10/18/2021, 9:22 AMFranco
10/18/2021, 10:18 AMturansky
10/18/2021, 10:22 AMuseParams
hook instead.
useParams
available for any component inside Route
Franco
10/18/2021, 11:22 AMturansky
10/18/2021, 12:57 PMProps
problems are common and they can have common solution. Extensions/adapters - backward step (we will describe details in issue)Franco
10/19/2021, 3:57 AMAndrey Nikanorov
10/26/2021, 1:02 PMturansky
10/26/2021, 1:04 PMAndrey Nikanorov
10/26/2021, 1:15 PMturansky
10/26/2021, 1:24 PMRComponent
Andrey Nikanorov
10/26/2021, 1:36 PMturansky
10/26/2021, 2:12 PMRouteComponentProps
as component props
And use match
property
(check required)Andrey Nikanorov
10/26/2021, 3:40 PMturansky
10/26/2021, 4:43 PMreact-router-dom
contract, non-specific for Kotlin