Skip to content

useRouter

ts
function useRouter(): Router;

Returns the router instance. Equivalent to using $router inside templates.

Returns

Router