Nuxt module tutorial: add product carousels and featured products to Nuxt Content Markdown posts and Vue pages, server-rendered, with your referral code on every link. Works with Nuxt 4 and Nuxt 3.17+.
βΆ Docs & live demo: https://avdeb.com/developers/#nuxt
π¦ Install: npm install nuxt-avdeb
π npm: https://www.npmjs.com/package/nuxt-avdeb
π» Source code: https://github.com/Avdebcom/nuxt-avdeb
In this video you'll:
β
Install nuxt-avdeb and add it to modules in nuxt.config.ts (layout and accent colour become defaults for every embed)
β
Put your referral code (or a server-only secret key, up to 48 products per embed) in .env
β
Drop the global components into a Nuxt Content Markdown post: a carousel from a category link + a hero featured product
β
See it server-rendered and cached: no layout shift, and it works with nuxt generate for static hosting
β
Use the Vue component in pages (spotlight layout) and the composable for your own markup
Every style rule has zero specificity, so your CSS always wins.
β± Chapters
0:00 What you'll build
0:12 Install the Nuxt module + referral code
0:39 Embed products in Nuxt Content Markdown
0:58 Server-rendered carousel + featured product
1:26 Vue components & composable in pages
1:43 Links & next steps
Commands used in this video:
$ npm install nuxt-avdeb
.env: NUXT_AVDEB_REF_CODE=YOURCODE
$ npx nuxi dev
π¬ Building with Nuxt Content or plain pages? Questions about the components or the composable? Ask in the comments.
#Nuxt #NuxtContent #Vue #avdeb #programmers #webdev