7 lines
166 B
TypeScript
7 lines
166 B
TypeScript
|
|
import { useParams } from 'react-router-dom';
|
||
|
|
|
||
|
|
export const useUrlId = (): string | undefined => {
|
||
|
|
const { id } = useParams<{ id?: string }>();
|
||
|
|
return id;
|
||
|
|
};
|