Gathering detailed insights and metrics for vue3-qr-code-styling
Gathering detailed insights and metrics for vue3-qr-code-styling
Gathering detailed insights and metrics for vue3-qr-code-styling
Gathering detailed insights and metrics for vue3-qr-code-styling
npm install vue3-qr-code-styling
Typescript
Module System
Node Version
NPM Version
TypeScript (79.59%)
JavaScript (14.79%)
Vue (5.61%)
Total Downloads
0
Last Day
0
Last Week
0
Last Month
0
Last Year
0
MIT License
35 Stars
14 Commits
47 Forks
1 Watchers
1 Branches
1 Contributors
Updated on Apr 23, 2025
Latest Version
1.4.6
Package Id
vue3-qr-code-styling@1.4.6
Unpacked Size
358.51 kB
Size
292.90 kB
File Count
39
NPM Version
8.6.0
Node Version
18.0.0
Cumulative downloads
Total Downloads
Last Day
0%
NaN
Compared to previous day
Last Week
0%
NaN
Compared to previous week
Last Month
0%
NaN
Compared to previous month
Last Year
0%
NaN
Compared to previous year
4
20
JavaScript library for generating QR codes with a logo and styling.
this clone copy of https://qr-code-styling.com
If you have issues / suggestions / notes / questions, please open an issue or contact me. Let's create a cool library together.
npm install vue3-qr-code-styling
1<template> 2 <div> 3 <VueQr3 4 :width="200" 5 :height="200" 6 data="https://diadal.com.ng" 7 :qrOptions="{ typeNumber: 0, mode: 'Byte', errorCorrectionLevel: 'H' }" 8 :imageOptions="{ hideBackgroundDots: true, imageSize: 0.4, margin: 0 }" 9 :dotsOptions="{ 10 type: 'dots', 11 color: '#26249a', 12 gradient: { 13 type: 'linear', 14 rotation: 0, 15 colorStops: [ 16 { offset: 0, color: '#26249a' }, 17 { offset: 1, color: '#26249a' }, 18 ], 19 }, 20 }" 21 :backgroundOptions="{ color: '#ffffff' }" 22 image="https://diadal.com.ng/icons/favicon-96x96.png" 23 :cornersSquareOptions="{ type: 'dot', color: '#000000' }" 24 :cornersDotOptions="{ type: undefined, color: '#000000' }" 25 fileExt="png" 26 :download="true" 27 myclass="my-qur" 28 imgclass="img-qr" 29 downloadButton="my-button" 30 :downloadOptions="{ name: 'vqr', extension: 'png' }" 31 > 32 </VueQr3> 33 </div> 34</template> 35 36<script lang="ts"> 37import { 38 defineComponent, 39 onBeforeUnmount, 40 defineAsyncComponent 41} from 'vue' 42 43export default defineComponent({ 44 name: 'VueQr3', 45 components: { 46 VueQr3: defineAsyncComponent(() => 47 Promise.resolve(import('vue3-qr-code-styling')) 48 ) 49 }, 50 setup () { 51 return { 52 } 53 } 54}) 55</script> 56 57<style lang="sass"> 58.my-qur 59// overflow-wrap: anywhere 60</style>
new VQRCodeStyling(options) => VQRCodeStyling
Param | Type | Description |
---|---|---|
options | object | Init object |
options
structure
Property | Type | Default Value | Description |
---|---|---|---|
width | number | 300 | Size of canvas |
height | number | 300 | Size of canvas |
download | boolean | false | To endable download button |
myclass | string | '' | Image DIV class |
imgclass | string | '' | Image class |
downloadButton | string | '' | download button class |
downloadOptions | object | download option name and extension | |
data | string | The date will be encoded to the QR code | |
image | string | The image will be copied to the center of the QR code | |
margin | number | 0 | Margin around canvas |
qrOptions | object | Options will be passed to qrcode-generator lib | |
imageOptions | object | Specific image options, details see below | |
dotsOptions | object | Dots styling options | |
cornersSquareOptions | object | Square in the corners styling options | |
cornersDotOptionsHelper | object | Dots in the corners styling options | |
backgroundOptions | object | QR background styling options |
options.qrOptions
structure
Property | Type | Default Value |
---|---|---|
typeNumber | number (0 - 40 ) | 0 |
mode | string ('Numeric' 'Alphanumeric' 'Byte' 'Kanji' ) | |
errorCorrectionLevel | string ('L' 'M' 'Q' 'H' ) | 'Q' |
options.imageOptions
structure
Property | Type | Default Value | Description |
---|---|---|---|
hideBackgroundDots | boolean | true | Hide all dots covered by the image |
imageSize | number | 0.4 | Coefficient of the image size. Not recommended to use ove 0.5. Lower is better |
margin | number | 0 | Margin of the image in px |
crossOrigin | string('anonymous' 'use-credentials' ) | Set "anonymous" if you want to download QR code from other origins. |
options.dotsOptions
structure
Property | Type | Default Value | Description |
---|---|---|---|
color | string | '#000' | Color of QR dots |
gradient | object | Gradient of QR dots | |
type | string ('rounded' 'dots' 'classy' 'classy-rounded' 'square' 'extra-rounded' ) | 'square' | Style of QR dots |
options.backgroundOptions
structure
Property | Type | Default Value |
---|---|---|
color | string | '#fff' |
gradient | object |
options.cornersSquareOptions
structure
Property | Type | Default Value | Description |
---|---|---|---|
color | string | Color of Corners Square | |
gradient | object | Gradient of Corners Square | |
type | string ('dot' 'square' 'extra-rounded' ) | Style of Corners Square |
options.cornersDotOptions
structure
Property | Type | Default Value | Description |
---|---|---|---|
color | string | Color of Corners Dot | |
gradient | object | Gradient of Corners Dot | |
type | string ('dot' 'square' ) | Style of Corners Dot |
Gradient structure
options.dotsOptions.gradient
options.backgroundOptions.gradient
options.cornersSquareOptions.gradient
options.cornersDotOptions.gradient
Property | Type | Default Value | Description |
---|---|---|---|
type | string ('linear' 'radial' ) | "linear" | Type of gradient spread |
rotation | number | 0 | Rotation of gradient in radians (Math.PI === 180 degrees) |
colorStops | array of objects | Gradient colors. Example [{ offset: 0, color: 'blue' }, { offset: 1, color: 'red' }] |
Gradient colorStops structure
options.dotsOptions.gradient.colorStops[]
options.backgroundOptions.gradient.colorStops[]
options.cornersSquareOptions.gradient.colorStops[]
options.cornersDotOptions.gradient.colorStops[]
Property | Type | Default Value | Description |
---|---|---|---|
offset | number (0 - 1 ) | Position of color in gradient range | |
color | string | Color of stop in gradient range |
VQRCodeStyling.append(container) => void
Param | Type | Description |
---|---|---|
container | DOM element | This container will be used for appending of the QR code |
VQRCodeStyling.update(options) => void
Param | Type | Description |
---|---|---|
options | object | The same options as for initialization |
VQRCodeStyling.download(downloadOptions) => void
Param | Type | Description |
---|---|---|
downloadOptions | object | Options with extension and name of file (not required) |
downloadOptions
structure
Property | Type | Default Value | Description |
---|---|---|---|
name | string | 'qr' | Name of the downloaded file |
extension | string ('png' 'jpeg' 'webp' ) | 'png' | File extension |
if any issue check
also you can buy me a coffee @ Patreon
MIT License. Copyright (c) 2021 Diadal Nig
No vulnerabilities found.
Reason
no binaries found in the repo
Reason
0 existing vulnerabilities detected
Reason
license file detected
Details
Reason
0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0
Reason
Found 0/14 approved changesets -- score normalized to 0
Reason
no SAST tool detected
Details
Reason
no effort to earn an OpenSSF best practices badge detected
Reason
security policy file not detected
Details
Reason
project is not fuzzed
Details
Reason
branch protection not enabled on development/release branches
Details
Score
Last Scanned on 2025-07-07
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