Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: add VueJS example to the main README.md file #138

Open
wants to merge 2 commits into
base: develop
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions AUTHORS.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,3 +6,4 @@
* Michael Mason
* Benjamin Besse <[email protected]>
* Marek Vavrecan <[email protected]>
* Mohammad Mahdi Nikrouz <[email protected]>
25 changes: 24 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -62,9 +62,32 @@ Check out [node-qrious](https://github.com/neocotic/node-qrious) if you want to
</body>
</html>
```

Open up `demo.html` in your browser to play around a bit.


### useing qrious in VueJS
component.vue
``` javascript
<script>
import QRious from 'qrious';
mounted() {
new QRious({
element: this.$refs.qrcode,
value: 'https://www.example.com'
});
}
</script>

<template>
<div>
<canvas ref="qrcode"></canvas>
</div>
</template>
```




## API

Simply create an instance of `QRious` and you've done most of the work. You can control many aspects of the QR code
Expand Down