Skip to content

How to use definePage's props property? #513

Answered by posva
a1mersnow asked this question in Q&A
Discussion options

You must be logged in to vote

For the moment you can cast the route with as RouteLocationNormalizedLoaded<'/users/[id]'>. Maybe in the future, definePage can be imported from a local ./$types but I think it will be simply easier to directly use useRoute(), which is easier to type, because in the future it will also allow other types than string and string[]

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by a1mersnow
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants