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 0d354b8 commit 512bd78Copy full SHA for 512bd78
resources/js/types/ziggy.d.ts
@@ -1,12 +1,11 @@
1
-import { Config, RouteParams } from 'ziggy-js';
+import { Router as ZiggyRouter } from 'ziggy-js';
2
3
-declare global {
4
- function route(): Config;
5
- function route(name: string, params?: RouteParams<typeof name> | undefined, absolute?: boolean): string;
6
-}
+type AppRouter = {
+ (): ZiggyRouter;
+ (name: string, params?: any, absolute?: boolean): string;
+};
7
8
-declare module '@vue/runtime-core' {
9
- interface ComponentCustomProperties {
10
- route: typeof route;
11
- }
+declare global {
+ // eslint-disable-next-line no-var
+ var route: AppRouter;
12
}
0 commit comments