or.npm put up -D nuxt-typed-router@legacy.Setup.Register the module in the nuxt.config.ts, done!export nonpayment defineNuxtConfig( modules: [' nuxt-typed-router'],. ).Example Usage.pages/login. vue.When a route has no params defined, the params residential or commercial property will certainly not even be available as an alternative in the hub.router.push('/ login/bar')// Mistake!router.push( label: 'login', params: foo: 'club')// Inaccuracy!router.push(" https://vuejsfeed.com/login")// Great!router.push( name: 'login')// Excellent!pages/user/ [i.d.] vue.When a route has actually a needed param described, browsing precisely to this option will certainly throw an inaccuracy if you do not give a params residential property or even if you put an incorrect param.router.push( label: 'user-id')// Error!router.push( name: 'user-id', params: bar: 'baz')// Error!router.push('/ individual')// Error!const i.d.="ey7878".router.push('/ individual/$ id ')// Great!router.push( name: 'user-id', params: id)// Great!router.push('/ individual/$ i.d./ baguette')// Error!For addressed routes, the params residential or commercial property will be readily available and the right way keyed in.const option = useRoute().if (route.name === 'foo') console.log( route.params.baz)// Inaccuracy!console.log( route.params.foo)// Really good!