0

I am working with App.svelte and in main I wrote the following code

<p>
<pre>
test
</pre>
</p>

but it results in an error

[plugin:vite-plugin-svelte] /src/App.svelte:209:0 &#60;/p> attempted to close &#60;p> that was already automatically closed by &#60;pre>
/src/App.svelte:209:0
207 |  
 208 | </pre>
 209 |  </p>
        ^
 210 |  
 211 |   <hr>
Click outside or fix the code to dismiss.
You can also disable this overlay by setting server.hmr.overlay to false in vite.config.js. 

I expected <p><pre>test</pre></p> is a valid html code.

sepp2k
  • 363,768
  • 54
  • 674
  • 675

0 Answers0