Skip to content

Migrating from nuxt-toc 2.x

v2.xv3.0.0
Content v2 onlyContent v2 or v3
Internal CustomQueryVersion-specific plugins
Config key loosely nuxt-tocnuxtToc
Heavy blog playgroundDual minimal playgrounds

Update config:

ts
export default defineNuxtConfig({
  modules: ['nuxt-toc', '@nuxt/content'],
  nuxtToc: {
    collection: 'content', // v3
  },
})

Prefer :toc="page.body?.toc"; auto-fetch still works when Content is installed.

Released under the MIT License.