1. Reference
  2. Display

<qr>

A QR code drawn on the device from any text or link; it redraws when its value changes.

Display
qr.ham
<column style="items-center gap-12">
    <qr value="https://hypeapps.dev/join/ABCDE"
        size="200"
        color="#0D1117"
        background="white"/>
    <text style="font-semibold">Scan to join the game</text>
    <text style="muted text-sm">Room code ABCDE</text>
</column>
The snippet drawn by Hype Apps on a phone, in light mode The snippet drawn by Hype Apps on a phone, in dark mode
This snippet as Hype Apps draws it on a phone. It follows this page's light or dark theme.

Attributes

NameWhat it doesDefault
background Background and quiet-zone color
color
white
color Module (dark square) color
color
black
size Width and height in pixels, quiet zone included
number
160
value The text or address to encode
string

Any tag also takes gestures: @on.tap, @on.longpress, @on.doubletap and @on.swipeleft (and right, up and down). @click runs on a tap too.

Guides and recipes that use it

This page is also Markdown, and all of HAM is in llms.txt.