pablohirafuji / elm-qrcode

QR Code in Elm

Home Page:http://package.elm-lang.org/packages/pablohirafuji/elm-qrcode/latest

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

QR Code

QR Code encoding and rendering. Demo.

Basic Usage

import Html exposing (Html)
import QRCode
import Svg.Attributes as SvgA

qrCodeView : String -> Html msg
qrCodeView message =
    QRCode.fromString message
        |> Result.map
            (QRCode.toSvg
                [ SvgA.width "100px"
                , SvgA.height "100px"
                ]
            )
        |> Result.withDefault (Html.text "Error while encoding to QRCode.")

If you would like more functionalities, please open an issue on GitHub.

Thanks

Thank you Carolyn Eby, for creating this great tutorial on how QR Code works.

Thank you Evan for bringing joy to the frontend.

About

QR Code in Elm

http://package.elm-lang.org/packages/pablohirafuji/elm-qrcode/latest

License:BSD 3-Clause "New" or "Revised" License


Languages

Language:Elm 100.0%