QrcodeController

QrcodeController

QR Code Generator Controller

Generates QR codes dynamically using the qrcode library. Generates the QR code when the modal/container is shown to avoid unnecessary generation.

Usage:

Or with a modal:

Constructor

new QrcodeController()

Source:

Methods

(async) copyToClipboard()

Description:
  • Copy QR code to clipboard as image

Source:

(async) download()

Description:
  • Download the QR code as PNG

Source:

generate()

Description:
  • Generate the QR code Returns a Promise that resolves when generation is complete

Source:

regenerate()

Description:
  • Regenerate the QR code (useful if URL changes)

Source: