mirror of
https://github.com/nuxt/nuxt.git
synced 2024-11-22 05:35:13 +00:00
fix(nuxt): export refreshCookie
(#25635)
This commit is contained in:
parent
460e0cfebd
commit
9af0e35ffc
@ -22,7 +22,7 @@ export { clearError, createError, isNuxtError, showError, useError } from './err
|
|||||||
export type { NuxtError } from './error'
|
export type { NuxtError } from './error'
|
||||||
export { useFetch, useLazyFetch } from './fetch'
|
export { useFetch, useLazyFetch } from './fetch'
|
||||||
export type { FetchResult, UseFetchOptions } from './fetch'
|
export type { FetchResult, UseFetchOptions } from './fetch'
|
||||||
export { useCookie } from './cookie'
|
export { useCookie, refreshCookie } from './cookie'
|
||||||
export type { CookieOptions, CookieRef } from './cookie'
|
export type { CookieOptions, CookieRef } from './cookie'
|
||||||
export { prerenderRoutes, useRequestHeaders, useRequestEvent, useRequestFetch, setResponseStatus } from './ssr'
|
export { prerenderRoutes, useRequestHeaders, useRequestEvent, useRequestFetch, setResponseStatus } from './ssr'
|
||||||
export { onNuxtReady } from './ready'
|
export { onNuxtReady } from './ready'
|
||||||
|
@ -120,6 +120,7 @@ describe('composables', () => {
|
|||||||
'preloadPayload',
|
'preloadPayload',
|
||||||
'preloadRouteComponents',
|
'preloadRouteComponents',
|
||||||
'reloadNuxtApp',
|
'reloadNuxtApp',
|
||||||
|
'refreshCookie',
|
||||||
'useCookie',
|
'useCookie',
|
||||||
'useFetch',
|
'useFetch',
|
||||||
'useHead',
|
'useHead',
|
||||||
@ -625,7 +626,7 @@ describe('callOnce', () => {
|
|||||||
const execute = () => callOnce(fn)
|
const execute = () => callOnce(fn)
|
||||||
await Promise.all([execute(), execute(), execute()])
|
await Promise.all([execute(), execute(), execute()])
|
||||||
expect(fn).toHaveBeenCalledTimes(1)
|
expect(fn).toHaveBeenCalledTimes(1)
|
||||||
|
|
||||||
const fnSync = vi.fn().mockImplementation(() => { })
|
const fnSync = vi.fn().mockImplementation(() => { })
|
||||||
const executeSync = () => callOnce(fnSync)
|
const executeSync = () => callOnce(fnSync)
|
||||||
await Promise.all([executeSync(), executeSync(), executeSync()])
|
await Promise.all([executeSync(), executeSync(), executeSync()])
|
||||||
|
Loading…
Reference in New Issue
Block a user