<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Labnan</title>
    <description>The latest articles on DEV Community by Labnan (@labnan).</description>
    <link>https://dev.to/labnan</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F748944%2F9d5c0f2a-8889-47eb-8d19-b2b9d7e82f7b.png</url>
      <title>DEV Community: Labnan</title>
      <link>https://dev.to/labnan</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/labnan"/>
    <language>en</language>
    <item>
      <title>Be Aware of the !-- script Bug</title>
      <dc:creator>Labnan</dc:creator>
      <pubDate>Sun, 21 Nov 2021 07:21:43 +0000</pubDate>
      <link>https://dev.to/labnan/a-string-that-might-break-your-front-end-1pgp</link>
      <guid>https://dev.to/labnan/a-string-that-might-break-your-front-end-1pgp</guid>
      <description>&lt;p&gt;Lets say you have this string in a variable (case insensitive):&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;`etc etc etc&amp;lt;!-- etc etc&amp;lt;scRipT&amp;gt; etc`
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This will break any html tag after it.&lt;/p&gt;

&lt;p&gt;Or lets say you divided that into some variables:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;const first = `etc etc etc &amp;lt;!--`;
const second = `anything`;
const third = `&amp;lt;script&amp;gt;`
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This will also break the html page.&lt;/p&gt;

&lt;p&gt;Therefore please carefully assign any string that contains&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;`&amp;lt;!--&amp;lt;script&amp;gt;` 
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;or similar into a variable, if it is inside &lt;code&gt;&amp;lt;script&amp;gt;&lt;/code&gt; tag.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://codepen.io/Labnan/pen/XWaQNxV"&gt;codepen example&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Edit: The original title is changed&lt;/p&gt;

&lt;p&gt;Feel free to ask any question related to this in the comments :)&lt;/p&gt;

</description>
      <category>security</category>
      <category>webdev</category>
      <category>javascript</category>
      <category>html</category>
    </item>
  </channel>
</rss>
