mirror of
https://github.com/nuxt/nuxt.git
synced 2025-02-16 13:48:13 +00:00
docs: use toUTCString
in useAsyncData
example (#5798)
This commit is contained in:
parent
ac4e09b36b
commit
57130b4fbc
@ -91,7 +91,7 @@ Defaults can be overwritten, see [overwriting defaults](#overwriting-defaults) i
|
|||||||
|
|
||||||
You can overwrite `<NuxtLink>` defaults by creating your own link component using `defineNuxtLink`.
|
You can overwrite `<NuxtLink>` defaults by creating your own link component using `defineNuxtLink`.
|
||||||
|
|
||||||
```js [components/MyNuxtLink.js]
|
```js [components/MyNuxtLink.ts]
|
||||||
export default defineNuxtLink({
|
export default defineNuxtLink({
|
||||||
componentName: 'MyNuxtLink',
|
componentName: 'MyNuxtLink',
|
||||||
/* see signature below for more */
|
/* see signature below for more */
|
||||||
@ -100,7 +100,7 @@ export default defineNuxtLink({
|
|||||||
|
|
||||||
You can then use `<MyNuxtLink />` component as usual with your new defaults.
|
You can then use `<MyNuxtLink />` component as usual with your new defaults.
|
||||||
|
|
||||||
:button-link[Open on StackBlitz]{href="https://stackblitz.com/github/nuxt/framework/tree/main/examples/routing/nuxt-link?terminal=dev&file=/components/MyNuxtLink.js" blank}
|
:button-link[Open on StackBlitz]{href="https://stackblitz.com/github/nuxt/framework/tree/main/examples/routing/nuxt-link?terminal=dev&file=/components/MyNuxtLink.ts" blank}
|
||||||
|
|
||||||
### `defineNuxtLink` signature
|
### `defineNuxtLink` signature
|
||||||
|
|
||||||
|
@ -7,7 +7,7 @@ template: Example
|
|||||||
This example shows different ways to use `<NuxtLink>`.
|
This example shows different ways to use `<NuxtLink>`.
|
||||||
|
|
||||||
::alert{type=info icon=💡}
|
::alert{type=info icon=💡}
|
||||||
`components/myNuxtLink.js` defines a custom `<NuxtLink>`.
|
`components/myNuxtLink.ts` defines a custom `<NuxtLink>`.
|
||||||
::
|
::
|
||||||
|
|
||||||
::ReadMore{link="/api/components/nuxt-link"}
|
::ReadMore{link="/api/components/nuxt-link"}
|
||||||
|
@ -1 +1 @@
|
|||||||
export default req => `Hello world (${req.url.substr(1)}) (Generated at ${new Date().toGMTString()})`
|
export default req => `Hello world (${req.url.substr(1)}) (Generated at ${new Date().toUTCString()})`
|
Loading…
Reference in New Issue
Block a user