Skip to content

Instantly share code, notes, and snippets.

@marcoslebron
Created January 7, 2018 15:39
Show Gist options
  • Save marcoslebron/5bf104fd0f9a5ab5e7ddbb116d25dbaa to your computer and use it in GitHub Desktop.
Save marcoslebron/5bf104fd0f9a5ab5e7ddbb116d25dbaa to your computer and use it in GitHub Desktop.
How to generate qrcodes, using the rqrcode gem
- qr = RQRCode::QRCode.new(current_user.provisioning_uri("#{Platform.to_s} #{current_user.email}"), size: 8, level: :h)
table.qr
- qr.modules.each_index do |x|
tr
- qr.modules.each_index do |y|
- if qr.dark?(x,y)
td.black
- else
td.white
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment