Skip to content

Commit

Permalink
Generate QR code.
Browse files Browse the repository at this point in the history
  • Loading branch information
luanbt21 committed Dec 4, 2022
1 parent f0e8c16 commit 04ae824
Show file tree
Hide file tree
Showing 5 changed files with 581 additions and 14 deletions.
16 changes: 16 additions & 0 deletions genQRCode.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
import QRCode from 'easyqrcodejs-nodejs'

const qrcode = new QRCode({
text: 'https://beelearn.social/',
logo: 'static/logo.png',
width: 500,
height: 500,
dotScale: 0.9,
quietZone: 20,
title: 'BeeLearnSocial',
titleTop: -5,
})

qrcode.saveImage({
path: 'qrcode.png',
})
2 changes: 2 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
"seed": "node prisma/seed.js"
},
"scripts": {
"genqr": " node genQRCode.mjs",
"dev": "concurrently 'vite' 'typesafe-i18n'",
"generate": "prisma generate",
"prebuild": "prisma generate",
Expand Down Expand Up @@ -62,6 +63,7 @@
"cookie": "^0.5.0",
"daisyui": "^2.42.1",
"dayjs": "^1.11.6",
"easyqrcodejs-nodejs": "^4.4.5",
"eventsource": "^2.0.2",
"firebase": "^9.14.0",
"firebase-admin": "^11.3.0",
Expand Down
Loading

0 comments on commit 04ae824

Please sign in to comment.