Getting started

Introduction

Learn what comark-etiket is, how it turns Comark directives into inline SVG or PNG at parse time, and when to use it.

comark-etiket is a Comark plugin for etiket barcodes and QR codes. It turns directives into inline SVG (or PNG) at parse time.

Renderer-agnostic output — no framework component required.

What it does

  • Parses Comark directives such as ::qrcode, ::barcode, and ::postal
  • Calls etiket encoders and injects SVG or PNG into the AST
  • Supports QR helpers (::qr-wifi, ::qr-vcard, …), batch sheets, and frontmatter defaults
  • Soft-validates inputs and falls back to a visible error node instead of throwing

When to use it

Use comark-etiket when you need barcodes or QR codes inside Comark markdown:

  • Static docs or PDF output with parse-time SVG
  • Vue apps with @comark/vue — SVG is already in the AST, no special component
  • PDF hosts that call renderEtiketSvg for runtime-bound values

What it is not

  • Not a reimplementation of etiket encoders — generation is provided by etiket
  • Not a terminal QR renderer — use etiket directly for qrcodeTerminal
  • Not an escape hatch for arbitrary etiket functions — use named directives only

See Feature coverage for the full status matrix.

Copyright © 2026