Skip to content

Commit e222814

Browse files
docs: update cookbook sidebar
1 parent 4e03c62 commit e222814

File tree

3 files changed

+18
-3
lines changed

3 files changed

+18
-3
lines changed

docs/.vitepress/config.ts

Lines changed: 17 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ export default defineConfig({
4141
'/guide/': sidebarGuide(),
4242
'/placeholders/': sidebarGuide(),
4343
'/integrations/': sidebarGuide(),
44-
'/cookbook/': sidebarGuide(),
44+
'/cookbook/': sidebarCookbook(),
4545
'/api/': sidebarApi(),
4646
},
4747

@@ -198,7 +198,7 @@ function sidebarGuide(): DefaultTheme.SidebarItem[] {
198198
]
199199
}
200200

201-
function sidebarApi(): DefaultTheme.SidebarItem[] {
201+
function sidebarCookbook(): DefaultTheme.SidebarItem[] {
202202
return [
203203
{
204204
text: 'Overview',
@@ -226,3 +226,18 @@ function sidebarApi(): DefaultTheme.SidebarItem[] {
226226
},
227227
]
228228
}
229+
230+
function sidebarApi(): DefaultTheme.SidebarItem[] {
231+
return [
232+
{
233+
text: 'Overview',
234+
link: '/cookbook/',
235+
},
236+
{
237+
text: 'Articles',
238+
items: [
239+
{ text: 'Aspect Ratio', link: '/cookbook/aspect-ratio' },
240+
],
241+
},
242+
]
243+
}

docs/integrations/nuxt.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -83,6 +83,7 @@ The `UnLazyImage` component accepts the following props:
8383
| `blurhash` | String | A BlurHash string representing the blurry placeholder image. |
8484
| `placeholderSize` | Number | The size of the longer edge (width or height) of the BlurHash image to be decoded, depending on the aspect ratio. This option only applies when the `blurhash` prop is used. |
8585
| `placeholderRatio` | Number | Aspect ratio (width / height) of the decoded BlurHash image. Only applies to SSR-decoded placeholder images from a BlurHash string. |
86+
| `lazyLoad` | Boolean | A flag to indicate whether the image should be lazy-loaded (default) or deferred until this prop is set to `true`. Note: Placeholder images from hashes will still be decoded. |
8687
| `ssr` | Boolean | Whether the ThumbHash or BlurHash should be decoded on the server. Overrides the global module configuration if set. |
8788

8889
## Examples

packages/nuxt/playground/app.vue

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,6 @@ const logoUrl = new URL('../../../docs/public/logo.svg', import.meta.url).href
1010
const shouldLoadImage = ref(false)
1111
1212
function loadImage() {
13-
console.log('load image')
1413
shouldLoadImage.value = true
1514
}
1615
</script>

0 commit comments

Comments
 (0)