# canvas-qrcode-logo

> Generate QRcode with logo, only support Canvas.

Latest version **1.1.1** (published 2019-08-05) · ISC license · 0 weekly downloads

## Install

```sh
npm install canvas-qrcode-logo
pnpm add canvas-qrcode-logo
yarn add canvas-qrcode-logo
bun add canvas-qrcode-logo
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.1.1 |
| Published | 2019-08-05 |
| First published | 2019-06-09 |
| Weekly downloads | 0 |
| License | ISC |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 0 |
| Unpacked size | 65.4 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 4 |
| Author | satrong |
| Maintainers | satrong |
| Keywords | qrcode, qrcode, logo |

## Links

- npm: https://www.npmjs.com/package/canvas-qrcode-logo
- Repository: https://github.com/satrong/canvas-qrcode-logo
- Homepage: https://github.com/satrong/canvas-qrcode-logo#readme
- Issues: https://github.com/satrong/canvas-qrcode-logo/issues
- npm.io page: https://npm.io/package/canvas-qrcode-logo

## Alternatives

- [jsforce](https://npm.io/package/jsforce.md) — 851.2K weekly downloads
- [react-native-qrcode-svg](https://npm.io/package/react-native-qrcode-svg.md) — 693.5K weekly downloads
- [@salesforce/plugin-data](https://npm.io/package/@salesforce/plugin-data.md) — 394.9K weekly downloads
- [@backstage/plugin-search-common](https://npm.io/package/@backstage/plugin-search-common.md) — 308.5K weekly downloads
- [@chain-registry/types](https://npm.io/package/@chain-registry/types.md) — 38.4K weekly downloads

## Recent versions

- 1.1.1 (latest) — 2019-08-05
- 1.1.0 — 2019-08-05
- 1.0.0 — 2019-06-09

## README

> Generate QRcode with logo, only support Canvas.

# Usage
```js
new QRCode(dom, options)
```

## NPM
```shell
npm i canvas-qrcode-logo
```

```js
const QRCode = require('canvas-qrcode-logo');
new QRCode(document.getElementById("qrcode"), {
        logo: './logo.png',
        text: "https://www.xiaoboy.com",
        width: 128,
        height: 128
    });
```

## Direct <script> Include
```html
<script src="../qrcode.min.js"></script>
<div id="qrcode"></div>
<script type="text/javascript">
    new QRCode.default(document.getElementById("qrcode"), {
        logo: './logo.png',
        text: "https://www.xiaoboy.com",
        width: 128,
        height: 128
    });
</script>
```

# Options
- `width` `{Number}` QRCode's width
- `height` `{Number}` QRCode's height
- `typeNumber` `{Number}`
- `colorDark` `{String}` default: `#000000`
- `colorLight``{String}` default: `#ffffff`,
- `correctLevel` `{String}` L | M | Q | H, default: `H`
- `logo` `{String}` logo's url,
- `padding` `{Number}` white space, default: 5
- `size` `{Number}` logo's width and height, default: 30

---
_Source: https://npm.io/package/canvas-qrcode-logo · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
