Banner

Show a banner on the top of the page.

app.config.ts
export default defineAppConfig({
  shadcnDocs: {
    banner: {
      enable: true,
      showClose: true,
      content: 'Welcome to **shadcn-docs-nuxt**',
      to: 'https://github.com/ZTL-UwU/shadcn-docs-nuxt',
      target: '_blank',
      border: true,
    },
  },
});

Preview

Parameters

enableboolean
false
Whether to enable the banner.
showCloseboolean
true
Whether to show to close button.
tostring
Link to navigate to. Don't set any value if you don't want to navigate.
contentstring
The content to show (parsed by the MDC parser).
targetTarget
_blank
Navigation target.
borderboolean
true
Whether to show the border at the bottom of the banner.