From e91ba08e9d031d73c0abb92c7fd3a437bacd2cf0 Mon Sep 17 00:00:00 2001 From: okxiaoliang4 <353742991@qq.com> Date: Thu, 14 Jul 2022 00:38:29 +0800 Subject: [PATCH] fix(useJwt)!: rename type `JwtOptions` to `UseJwtOptions` and `JwtResult` to `UseJwtReturn` --- packages/integrations/useJwt/index.ts | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/packages/integrations/useJwt/index.ts b/packages/integrations/useJwt/index.ts index ab6dad51645..30f1f361488 100644 --- a/packages/integrations/useJwt/index.ts +++ b/packages/integrations/useJwt/index.ts @@ -5,7 +5,7 @@ import { resolveUnref } from '@vueuse/shared' import jwt_decode from 'jwt-decode' import type { JwtDecodeOptions, JwtHeader, JwtPayload } from 'jwt-decode' -export interface JwtOptions { +export interface UseJwtOptions { /** * Value returned when encounter error on decoding * @@ -19,7 +19,7 @@ export interface JwtOptions { onError?: (error: unknown) => void } -export interface JwtResult { +export interface UseJwtReturn { header: ComputedRef
payload: ComputedRef } @@ -36,8 +36,8 @@ export function useJwt< Fallback = null, >( encodedJwt: MaybeComputedRef, - options: JwtOptions = {}, -): JwtResult { + options: UseJwtOptions = {}, +): UseJwtReturn { const { onError, fallbackValue = null,