Gathering detailed insights and metrics for vanillaqr
Gathering detailed insights and metrics for vanillaqr
Gathering detailed insights and metrics for vanillaqr
Gathering detailed insights and metrics for vanillaqr
The galaxy's most resilient javascript QR code generator
npm install vanillaqr
Typescript
Module System
Node Version
NPM Version
75.3
Supply Chain
99.1
Quality
75
Maintenance
100
Vulnerability
100
License
JavaScript (94.27%)
HTML (4.83%)
CSS (0.57%)
Shell (0.32%)
Total Downloads
25,813
Last Day
3
Last Week
233
Last Month
964
Last Year
10,561
MIT License
76 Stars
21 Commits
17 Forks
3 Watchers
2 Branches
3 Contributors
Updated on Jun 04, 2025
Minified
Minified + Gzipped
Latest Version
1.0.0
Package Id
vanillaqr@1.0.0
Unpacked Size
81.39 kB
Size
23.69 kB
File Count
8
NPM Version
6.13.7
Node Version
8.9.1
Cumulative downloads
Total Downloads
Last Day
200%
3
Compared to previous day
Last Week
10.4%
233
Compared to previous week
Last Month
-32.7%
964
Compared to previous month
Last Year
396.8%
10,561
Compared to previous year
1
A small javascript file for creating qr codes on the fly using the HTML5 Canvas element. By default VanillaQR.js will output a canvas element as it's domElement. If the canvas element and 2d context is not supported, it will create a table instead. Tables will not be able to output images so be sure to check that the image element exists.
1<script src="VanillaQR.min.js"></script>
2<script>
3
4//Create qr object
5//Minus the url, these are the defaults
6var qr = new VanillaQR({
7
8 url: "https://github.com/chuckfairy/VanillQR.js",
9 size: 280,
10
11 colorLight: "#ffffff",
12 colorDark: "#000000",
13
14 //output to table or canvas
15 toTable: false,
16
17 //Ecc correction level 1-4
18 ecclevel: 1,
19
20 //Use a border or not
21 noBorder: false,
22
23 //Border size to output at
24 borderSize: 4
25
26});
27
28//Canvas or table is stored in domElement property
29document.body.appendChild(qr.domElement);
30
31//Alternatively you can create an image from the canvas
32//png, jpg, jpeg, webp, gif, bmp, tiff, x-icon, svg+xml, xxx
33//Currently canvas dataURL mime types are not the same
34var imageElement = qr.toImage("png");
35
36if(imageElement) {
37 document.body.appendChild(imageElement);
38}
39
40
41//You can recreate the qr code to a new url like so
42//If you have appended the domElement it will change
43qr.url = "https://github.com/chuckfairy";
44qr.colorLight = "#0000000";
45qr.colorDark = "#ffffff";
46qr.init();
47
48</script>
Through module
1import VanillaQR from "VanillaQR" 2 3 4//See above for more 5var qr = new VanillaQR({ 6 url: "https://github.com/chuckfairy/VanillQR.js", 7});
All browsers with canvas and canvas 2d context support
Table support fallback
Vanilla QR is based on a port of a java qr code library that I can no longer find. When I do find it I'll be sure to give it proper credit. Thank you and have a nice day!
No vulnerabilities found.
Reason
no binaries found in the repo
Reason
0 existing vulnerabilities detected
Reason
license file detected
Details
Reason
Found 3/15 approved changesets -- score normalized to 2
Reason
0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0
Reason
no effort to earn an OpenSSF best practices badge detected
Reason
project is not fuzzed
Details
Reason
security policy file not detected
Details
Reason
branch protection not enabled on development/release branches
Details
Reason
SAST tool is not run on all commits -- score normalized to 0
Details
Score
Last Scanned on 2025-06-23
The Open Source Security Foundation is a cross-industry collaboration to improve the security of open source software (OSS). The Scorecard provides security health metrics for open source projects.
Learn More