We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent e919c1d commit abc918fCopy full SHA for abc918f
docs/guide/advanced/meta.md
@@ -58,10 +58,14 @@ router.beforeEach((to, from) => {
58
59
## TypeScript
60
61
-It is possible to type the meta field by extending the `RouteMeta` interface:
+It is possible to type the meta field by extending the `RouteMeta` interface from `vue-router`:
62
63
```ts
64
-// typings.d.ts or router.ts
+// This can be directly added to any of your `.ts` files like `router.ts`
65
+// It can also be added to a `.d.ts` file, in which case you will need to add an export
66
+// to ensure it is treated as a module
67
+export {}
68
+
69
import 'vue-router'
70
71
declare module 'vue-router' {
0 commit comments