Vinkas UI

UTM Link

This is a shadcn/ui type react component that automatically adds UTM parameters to the href on click

Demo

  import { UTMLink } from '@/registry/vinkas/ui/utm-link'

  export function UTMLinkDemo() {
    return <UTMLink href="https://vinkas.com" source="vinkas" medium="utm-link" campaign="ui" target="_blank" rel="noopener">UTM Link</UTMLink>
  }

Installation

npx shadcn@latest add @vinkas-ui/utm-link
Make sure you already have the @vinkas-ui registry added to your components.json file. Read the installation guide for more information.

API Reference

See the Link documentation of nextjs for more information. Link is used as the base component for UTMLink.