feat: add support for optional dynamic route params (#1706)
This commit is contained in:
@@ -0,0 +1,9 @@
|
||||
interface Props {
|
||||
params: Record<string, string | string[]>;
|
||||
}
|
||||
|
||||
export default function Lang(props: Props) {
|
||||
return props.params.lang
|
||||
? <div>Hello {props.params.lang}</div>
|
||||
: <div>Hello</div>;
|
||||
}
|
||||
Reference in New Issue
Block a user