Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

345
Views
¿Cómo hacer que LiveSever Canvas cargue html?

Recientemente comencé a codificar un archivo de lienzo js/html y noté un gran problema que no puedo resolver. El problema es que la extensión LiverSever de repente dejó de funcionar. Lo que quiero decir con esto es que simplemente dejó de funcionar al azar. Cuando trato de abrirlo, se abre en el navegador pero sigue cargando. He intentado muchas correcciones pero ninguna de ellas parece funcionar. El "enlace" del puerto html es, " http://127.0.0.1:49423/index.html" . Entonces, me preguntaba si podría obtener ayuda.

código html a continuación:

 <head> <meta charset="UTF-8"> <meta http-equiv="X-UA-Compatible" content="IE=edge"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <title>Canvas</title> <style> canvas { border: 1px solid lightyellow; background: lightyellow; } body { margin: 0; } .tooltip { width: 100px; position: absolute; top: auto; bottom: 800px; right: 887px; left: auto; font-size: xx-large; } </style> </head> <body> <canvas></canvas> <script src="Main_Game.js"> </script> <div class="tooltip">Money: <script type="text/javascript">document.write(Moneys)</script> </div> </body> </html>

codigo js:

 var canvas = document.querySelector('canvas'); canvas.width = 1920; canvas.height = 1080; var middlex = canvas.width/2; console.log(middlex + " - x"); var middley = canvas.height/2; console.log(middley + " - y"); console.log(canvas); var c = canvas.getContext('2d'); c.fillStyle = 'rgba(255,0,0)'; c.fillRect(25,540,940,250); c.fillRect(25, 815, 940,250); c.fillRect(985,540,915,250); c.fillRect(985,815,915,250); c.beginPath(); c.arc(200, 200, 30, 0, Math.PI*2, false); c.strokeStyle = 'blue'; c.stroke(); var Moneys = 0; while (true) { Moneys += 1; }
about 4 years ago · Juan Pablo Isaza
1 answers
Answer question

0

no se como borrar. Descubrí que el nombre del html no era el mismo que el del archivo js

about 4 years ago · Juan Pablo Isaza Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!