Skip to content

Presets

@masumdev/rn-qr-code includes 16+ pre-configured design presets exported via QR_CODE_CONFIGS:

PropTypeDefaultDescription
BASICPresetConfigStandard black & white square QR code with default size.
TRIANGLEPresetConfigGolden yellow (#DAA520) QR code with triangle corner eyes and triangle data modules.
HEARTPresetConfigPink QR code with heart-shaped corner eyes and heart data modules.
DOTPresetConfigDark slate (#483D8B) QR code with circular dot eyes and dot modules.
WITH_LOGOPresetConfigCenter embedded logo with custom blue square corner eye radii and dot modules.
RAINPresetConfigBlue (#2074a7) QR code with raindrop-shaped modules and rounded corner eyes.
LINEAR_GRADIENTPresetConfigMulti-stop Indigo / Pink / Purple / Blue linear gradient mask with center logo.
RADIAL_GRADIENTPresetConfigYellow to Forest Green radial gradient fill with rounded modules.
IMAGE_BACKGROUNDPresetConfigCircle eye shapes with error correction Level H and custom image background clip.

Using Presets Programmatically

PresetProgrammaticUsage.tsx
import { QRCode, QR_CODE_CONFIGS } from '@masumdev/rn-qr-code';
// Inspect preset keys programmatically
console.log(Object.keys(QR_CODE_CONFIGS));
// Render with preset
<QRCode value="Preset Demo" variant="LINEAR_GRADIENT" size={200} />