Skip to content

Commit

Permalink
Fix drawtext error (#938)
Browse files Browse the repository at this point in the history
1. Start QB-Core on a slow or low-spec computer
2. Access the Debug UI page (localhost:13172)
3. Encounter an error in the drawtext.js file
4. The issue stems from the script loading successfully but any resource call function (hideText) and sending an event message before index.html of all resources are fully loaded on NUI it make
`html
<div className="text" />` is not loaded.
  • Loading branch information
worapolburaphan authored Jan 31, 2023
1 parent 7b68f72 commit 14340bb
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions html/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,14 @@
<link href="css/style.css" rel="stylesheet" />
<script src="https://cdn.jsdelivr.net/npm/vue@3/dist/vue.global.prod.js" defer></script>
<script src="https://cdn.jsdelivr.net/npm/[email protected]/dist/quasar.umd.prod.js" defer></script>
<script type="module" src="js/app.js"></script>
<script src="js/drawtext.js"></script>
<link rel="stylesheet" href="css/drawtext.css">
</head>
<body style="font-family: 'Poppins', sans-serif">
<div id="q-app" style="min-height: 100vh"></div>
<div id="drawtext-container">
<div id="text" class="text"></div>
</div>
<script type="module" src="js/app.js"></script>
<script src="js/drawtext.js"></script>
</body>
</html>
</html>

0 comments on commit 14340bb

Please sign in to comment.