| 12345678910111213141516171819202122232425262728293031323334353637383940 |
- <template>
- <view class="">
- <text>123456</text>
- <poster ref="poster"></poster>
- <uqrcode class="canvas-hide" ref="uqrcode"></uqrcode>
- </view>
- </template>
- <script>
- import poster from "@/components/poster/poster.vue"
- import uqrcode from "@/components/uqrcode/uqrcode.vue"
- export default {
- components: {
- poster,
- uqrcode
- },
- data() {
- return {
- };
- },
- async onReady() {
- let res=await this.$refs.uqrcode.make({size: 150,text: '黄明潘'})
- this.$refs.poster.showCanvas(res.tempFilePath)
- },
- onLoad() {
-
- }
- };
- </script>
- <style lang="scss" scoped>
- .canvas-hide {
- position: fixed;
- right: 100vw;
- bottom: 100vh;
- z-index: -9999;
- opacity: 0;
- }
- </style>
|