mirror of
https://github.com/gosticks/DefinitelyTyped.git
synced 2026-06-28 14:20:12 +00:00
[nuxtjs__auth] added missing declarations (#40778)
* [nuxtjs__auth] added missing methods declarations * fixed missed semicolons
This commit is contained in:
committed by
Ron Buckton
parent
4b7a130a2d
commit
a26abc07b0
20
types/nuxtjs__auth/index.d.ts
vendored
20
types/nuxtjs__auth/index.d.ts
vendored
@@ -3,6 +3,7 @@
|
||||
// Definitions by: Ruskin Constant <https://github.com/jonnyparris>
|
||||
// Daniel Leal <https://github.com/danielgek>
|
||||
// Nick Bolles <https://github.com/NickBolles>
|
||||
// Andrii Rodionov <https://github.com/arodiono>
|
||||
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
|
||||
// TypeScript Version: 3.1
|
||||
|
||||
@@ -43,6 +44,13 @@ export interface Auth<T = any> {
|
||||
setUser(user?: Partial<T>): any;
|
||||
reset(): Promise<never>;
|
||||
redirect(name: string): any;
|
||||
strategy(): string;
|
||||
registerStrategy(strategyName: string, strategy: object): void;
|
||||
setStrategy(strategyName: string): void;
|
||||
setUserToken(): Promise<never>;
|
||||
getRefreshToken(strategyName: string): string;
|
||||
setRefreshToken(strategyName: string, token?: string): string;
|
||||
syncRefreshToken(strategyName: string): string;
|
||||
}
|
||||
|
||||
declare module 'vue/types/options' {
|
||||
@@ -56,3 +64,15 @@ declare module 'vue/types/vue' {
|
||||
$auth: Auth;
|
||||
}
|
||||
}
|
||||
|
||||
declare module '@nuxt/vue-app' {
|
||||
interface Context {
|
||||
$auth: Auth;
|
||||
}
|
||||
}
|
||||
|
||||
declare module '@nuxt/types' {
|
||||
interface Context {
|
||||
$auth: Auth;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user