文件操作 - utils.d.ts
返回文件管理
返回主菜单
删除本文件
文件: /var/www/OLD/node_modules/@nuxtjs/i18n/dist/runtime/utils.d.ts
编辑文件内容
import type { I18n, Locale } from 'vue-i18n'; import type { NuxtApp } from '#app'; import type { Ref } from '#imports'; import type { Router } from '#vue-router'; import type { HeadSafe } from '@unhead/vue'; import type { RuntimeConfig } from 'nuxt/schema'; import type { I18nPublicRuntimeConfig } from '#internal-i18n-types'; import type { PrefixableOptions, SwitchLocalePathIntercepter, BaseUrlResolveHandler, LocaleObject } from '#internal-i18n-types'; import type { CompatRoute } from './types.js'; /** * Common options used internally by composable functions, these * are initialized when calling a wrapped composable function. * * @internal */ export type CommonComposableOptions = { router: Router; i18n: I18n; runtimeConfig: RuntimeConfig & { public: { i18n: I18nPublicRuntimeConfig; }; }; metaState: Ref<Record<Locale, any>>; }; export declare function initCommonComposableOptions(i18n?: I18n): CommonComposableOptions; export declare function loadAndSetLocale(newLocale: Locale, initial?: boolean): Promise<boolean>; export declare function detectLocale(route: string | CompatRoute, routeLocale: string, currentLocale: string | undefined, localeCookie: string | undefined): string; type DetectRedirectOptions = { to: CompatRoute; from?: CompatRoute; /** * The locale we want to navigate to */ locale: Locale; /** * Locale detected from route */ routeLocale: string; }; /** * Returns a localized path to redirect to, or an empty string if no redirection should occur * * @param inMiddleware - whether this is called during navigation middleware */ export declare function detectRedirect({ to, from, locale, routeLocale }: DetectRedirectOptions, inMiddleware?: boolean): string; type NavigateArgs = { nuxtApp: NuxtApp; redirectPath: string; locale: string; route: CompatRoute; }; export declare function navigate({ nuxtApp, locale, route, redirectPath }: NavigateArgs, { status, enableNavigate }?: { status?: number; enableNavigate?: boolean; }): Promise<string | false | void | import("vue-router").RouteLocationAsRelativeGeneric | import("vue-router").RouteLocationAsPathGeneric | import("vue-router").NavigationFailure>; export declare function extendPrefixable(runtimeConfig?: RuntimeConfig): (opts: PrefixableOptions) => boolean; export declare function extendSwitchLocalePathIntercepter(runtimeConfig?: RuntimeConfig): SwitchLocalePathIntercepter; export declare function extendBaseUrl(): BaseUrlResolveHandler<NuxtApp>; export type HeadParam = Required<Pick<HeadSafe, 'meta' | 'link'>>; export declare function getNormalizedLocales(locales: string[] | LocaleObject[]): LocaleObject[]; export {};
修改文件时间
将文件时间修改为当前时间的前一年
删除文件