MCPcopy Create free account
hub / github.com/Xu22Web/tech-study-js / generateQRCode

Function generateQRCode

tech-study.js:471–487  ·  view source on GitHub ↗

* @description 生成二维码

()

Source from the content-addressed store, hash-verified

469 * @description 生成二维码
470 */
471async function generateQRCode() {
472 try {
473 // 推送
474 const res = await fetch(API_CONFIG.generateQRCode, {
475 method: 'GET',
476 mode: 'cors',
477 });
478 // 请求成功
479 if (res.ok) {
480 const data = await res.json();
481 if (data.success) {
482 return data.result;
483 }
484 }
485 }
486 catch (error) { }
487}
488/**
489 * @description 用二维码登录
490 */

Callers 1

getQRCodeFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected