Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

397
Visualizações
How to run eval() function on codeblock generated from quill.js?

I am trying to let the user input the codeblock in a stylish way and save them to run later. For that purpose I found quill. But the code block generated by quill is text with bunch of HTML code used to style. enter image description here

For the code above the text generated by quill is

"<pre class=\"ql-syntax\" spellcheck=\"false\">console.log('hello world') ;\nif(2&lt;3 &amp;&amp; 2+6==8)\n{\n  alert('i am an alert') \n}\n</pre>"

So how can I omit all the unnecessary texts and get only the code I have written as above so that I could on eval() function on the generated string ?

about 4 years ago · Juan Pablo Isaza
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda