alexisroe

QR Code

Component

About

An SVG QR code that encodes a plain string or structured data like a Wi-Fi credential, contact card, or 2FA secret, with an optional caption.

Built with React and Tailwind. Copy the prompt and paste it into Claude Code, Cursor or Lovable: your agent adds QR Code to your project and fits it to your theme.

Code

How QR Code is used: the demo's code. The component's own source comes with a free account.

Usage.tsx

import { QRCode } from "@/components/ui/qrcode";

export default function QRCodeContactDemo() {
  return (
    <div className="flex min-h-[320px] w-full items-center justify-center bg-white p-10">
      <QRCode
        value={{
          type: "contact",
          name: "Jane Doe",
          phone: "+1 555 123 4567",
          email: "[email protected]",
          organization: "Acme",
        }}
        label="Jane Doe"
        width={180}
      />
    </div>
  );
}

Dependencies

More by alexisroe

View all
  • Log

    Log

    7
  • Notification

    Notification

    2
  • Number Stepper

    Number Stepper

    2
  • Segmented Control

    Segmented Control

    2
  • Chip

    Chip

    2
  • Checkbox

    Checkbox

    1
  • E-Ink Code

    E-Ink Code

  • Breadcrumbs

    Breadcrumbs