<?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>Forem: Nikita Hlopov</title>
    <description>The latest articles on Forem by Nikita Hlopov (@nikitahl).</description>
    <link>https://forem.com/nikitahl</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%2F280558%2F90b129f9-9f19-4428-abf1-bbd0208c84d3.png</url>
      <title>Forem: Nikita Hlopov</title>
      <link>https://forem.com/nikitahl</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://forem.com/feed/nikitahl"/>
    <language>en</language>
    <item>
      <title>Accessible collapsible mobile navigation?</title>
      <dc:creator>Nikita Hlopov</dc:creator>
      <pubDate>Wed, 06 May 2020 13:48:54 +0000</pubDate>
      <link>https://forem.com/nikitahl/accessible-collapsible-mobile-navigation-5k5</link>
      <guid>https://forem.com/nikitahl/accessible-collapsible-mobile-navigation-5k5</guid>
      <description>&lt;p&gt;Hello!&lt;/p&gt;

&lt;p&gt;Upon searching the internet I realized that I couldn't find a decent explanation/example of an accessible collapsible menu with the classic "Hamburger" button.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://themes.getbootstrap.com/"&gt;Bootstrap&lt;/a&gt; example is pretty close to what I'm looking for. The hamburger button has &lt;code&gt;aria&lt;/code&gt; attributes but &lt;br&gt;
I feel like it's missing the accessibility features on the actual navigation when it gets toggled.&lt;/p&gt;

&lt;p&gt;Having said that, am I overcomplicating things or can someone point me to a resource/example of accessible navigation.&lt;/p&gt;

&lt;p&gt;Thanks.&lt;/p&gt;

</description>
      <category>help</category>
    </item>
    <item>
      <title>What's the dark mode priority should be?</title>
      <dc:creator>Nikita Hlopov</dc:creator>
      <pubDate>Thu, 30 Apr 2020 08:37:08 +0000</pubDate>
      <link>https://forem.com/nikitahl/what-s-the-dark-mode-priority-should-be-1b5d</link>
      <guid>https://forem.com/nikitahl/what-s-the-dark-mode-priority-should-be-1b5d</guid>
      <description>&lt;p&gt;From the UX perspective, what's the dark mode priority should be on a site,&lt;br&gt;
localStorage or user default computer theme?&lt;/p&gt;

&lt;p&gt;E.g. If a user has a dark theme by default (on a computer), and then the user enabled the light theme (switch on a site), then the next time the user enters a site what value should be applied (default or saved from the localStorage)?&lt;/p&gt;

&lt;p&gt;Or have I misunderstood this whole dark mode and doing something wrong?&lt;/p&gt;

</description>
      <category>help</category>
    </item>
    <item>
      <title>3 ways to add distinct underline style for the anchor tags </title>
      <dc:creator>Nikita Hlopov</dc:creator>
      <pubDate>Mon, 30 Mar 2020 08:13:34 +0000</pubDate>
      <link>https://forem.com/nikitahl/3-ways-to-add-distinct-underline-style-for-the-anchor-tags-363b</link>
      <guid>https://forem.com/nikitahl/3-ways-to-add-distinct-underline-style-for-the-anchor-tags-363b</guid>
      <description>&lt;p&gt;Add some slick &lt;em&gt;underline&lt;/em&gt; styles to your anchor tags with these 3 ways.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;text-decoration&lt;/li&gt;
&lt;li&gt;border&lt;/li&gt;
&lt;li&gt;box-shadow&lt;/li&gt;
&lt;/ol&gt;

&lt;h2&gt;
  
  
  1. text-decoration
&lt;/h2&gt;

&lt;p&gt;The first and most obvious way is to use the &lt;code&gt;text-decoration&lt;/code&gt; property to give your links a distinctive style. The &lt;a href="https://developer.mozilla.org/en-US/docs/Web/CSS/text-decoration"&gt;&lt;code&gt;text-decoration&lt;/code&gt;&lt;/a&gt; property is a shorthand that:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;sets the appearance of decorative lines on text&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;This property will set &lt;code&gt;text-decoration-line&lt;/code&gt;, &lt;code&gt;text-decoration-color&lt;/code&gt;, &lt;code&gt;text-decoration-style&lt;/code&gt;. However it can take from one up to three parameters.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight css"&gt;&lt;code&gt;&lt;span class="nt"&gt;a&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;text-decoration&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;underline&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;You can add more unique styles by throwing in the color and style properties:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight css"&gt;&lt;code&gt;&lt;span class="nt"&gt;a&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;text-decoration&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;underline&lt;/span&gt; &lt;span class="nb"&gt;dotted&lt;/span&gt; &lt;span class="m"&gt;#047cea&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Available styles are:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;solid;&lt;/li&gt;
&lt;li&gt;double;&lt;/li&gt;
&lt;li&gt;dotted;&lt;/li&gt;
&lt;li&gt;dashed;&lt;/li&gt;
&lt;li&gt;wavy.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  2. border
&lt;/h2&gt;

&lt;p&gt;The &lt;code&gt;border-bottom&lt;/code&gt; property will allow you to make &lt;em&gt;underline&lt;/em&gt; more custom.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight css"&gt;&lt;code&gt;&lt;span class="nt"&gt;a&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;text-decoration&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;none&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;border-bottom&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;1px&lt;/span&gt; &lt;span class="nb"&gt;dashed&lt;/span&gt; &lt;span class="m"&gt;#047cea&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Now you can control &lt;em&gt;underline&lt;/em&gt;'s width and use styles specific only to the &lt;code&gt;border&lt;/code&gt; property like:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;dotted;&lt;/li&gt;
&lt;li&gt;dashed;&lt;/li&gt;
&lt;li&gt;solid;&lt;/li&gt;
&lt;li&gt;double;&lt;/li&gt;
&lt;li&gt;groove;&lt;/li&gt;
&lt;li&gt;ridge;&lt;/li&gt;
&lt;li&gt;inset;&lt;/li&gt;
&lt;li&gt;outset.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Another benefit of using the &lt;code&gt;border-bottom&lt;/code&gt; property is you can control the space between the text and the &lt;em&gt;underline&lt;/em&gt; by adding a &lt;code&gt;padding&lt;/code&gt; property.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight css"&gt;&lt;code&gt;&lt;span class="nt"&gt;a&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;text-decoration&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;none&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;border-bottom&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;1px&lt;/span&gt; &lt;span class="nb"&gt;dashed&lt;/span&gt; &lt;span class="m"&gt;#047cea&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;padding-bottom&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;2px&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; 
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  3. box-shadow
&lt;/h2&gt;

&lt;p&gt;The last one is &lt;code&gt;box-shadow&lt;/code&gt; property. Like the &lt;code&gt;border&lt;/code&gt; it will allow you to control the width of the &lt;em&gt;underline&lt;/em&gt; and space between the text as well.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight css"&gt;&lt;code&gt;&lt;span class="nt"&gt;a&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;text-decoration&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;none&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;box-shadow&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;0&lt;/span&gt; &lt;span class="m"&gt;2px&lt;/span&gt; &lt;span class="m"&gt;#047cea&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;padding-bottom&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;3px&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Along with other properties like &lt;em&gt;blur&lt;/em&gt; and &lt;em&gt;spread&lt;/em&gt; which can create some funky effects.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight css"&gt;&lt;code&gt;&lt;span class="nt"&gt;a&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;text-decoration&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;none&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;box-shadow&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;0&lt;/span&gt; &lt;span class="m"&gt;2px&lt;/span&gt; &lt;span class="m"&gt;2px&lt;/span&gt; &lt;span class="m"&gt;-2px&lt;/span&gt; &lt;span class="m"&gt;#047cea&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;To conclude, if you want something more than a default styling use &lt;code&gt;border&lt;/code&gt; or &lt;code&gt;box-shadow&lt;/code&gt;. These properties also allow using transitions on them so you can get creative with hover effects. 😉&lt;/p&gt;

&lt;p&gt;I've put together a collection of possible anchor tag styles on CodePen, check 'em out.&lt;/p&gt;

&lt;p&gt;&lt;iframe height="600" src="https://codepen.io/nikitahl/embed/jvaPrp?height=600&amp;amp;default-tab=result&amp;amp;embed-version=2"&gt;
&lt;/iframe&gt;
&lt;/p&gt;

&lt;p&gt;Cover photo by &lt;a href="https://unsplash.com/@lum3n?utm_source=unsplash&amp;amp;utm_medium=referral&amp;amp;utm_content=creditCopyText"&gt;LUM3N&lt;/a&gt; on Unsplash&lt;/p&gt;

</description>
      <category>html</category>
      <category>css</category>
      <category>beginners</category>
      <category>webdev</category>
    </item>
    <item>
      <title>Become more productive with these 5 terminal tips</title>
      <dc:creator>Nikita Hlopov</dc:creator>
      <pubDate>Mon, 16 Mar 2020 13:44:14 +0000</pubDate>
      <link>https://forem.com/visualcomposer/become-more-productive-with-these-5-terminal-tips-2h75</link>
      <guid>https://forem.com/visualcomposer/become-more-productive-with-these-5-terminal-tips-2h75</guid>
      <description>&lt;p&gt;Five small tips to improve your terminal skills that I've learned from my teammate.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Change directory from root&lt;/li&gt;
&lt;li&gt;Line navigation&lt;/li&gt;
&lt;li&gt;Remove the line&lt;/li&gt;
&lt;li&gt;Repeat the previous command with &lt;code&gt;sudo&lt;/code&gt;
&lt;/li&gt;
&lt;li&gt;Suggestions with Tab button&lt;/li&gt;
&lt;/ol&gt;

&lt;h2&gt;
  
  
  1. Change directory from root
&lt;/h2&gt;

&lt;p&gt;From any directory location in your terminal, you can start directory change from the root folder. Right after &lt;code&gt;cd&lt;/code&gt; command add a Space and a / to begin change. E.g.:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;cd&lt;/span&gt; /
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;and then:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;cd&lt;/span&gt; /var/log/
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  2. Line navigation
&lt;/h2&gt;

&lt;p&gt;Navigate through your line with ease. Either jump to the start and end of the line:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
fn + shift(⇧) + ← - Jump to the start of the line&lt;/li&gt;
&lt;li&gt;
fn + shift(⇧) + → - Jump to the end of the line&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;or jump by word:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
alt(⌥) + ← - Jump to the previous word&lt;/li&gt;
&lt;li&gt;
alt(⌥) + → - Jump to the next word&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  3. Remove the line
&lt;/h2&gt;

&lt;p&gt;This command will remove all text in the current line and leave cursor blinking at the start:&lt;/p&gt;

&lt;p&gt;ctrl(⌃) + u&lt;/p&gt;

&lt;h2&gt;
  
  
  4. Repeat the previous command with &lt;code&gt;sudo&lt;/code&gt;
&lt;/h2&gt;

&lt;p&gt;Very handy if you need to repeat the command with superuser permissions:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;sudo&lt;/span&gt; &lt;span class="o"&gt;!!&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  5. Suggestions with Tab button
&lt;/h2&gt;

&lt;p&gt;Double-clicking on Tab button while writing a path to a file will show you suggestions (contents) of the directory. It comes in handy when you need to type in a long path.&lt;/p&gt;

&lt;p&gt;That's it for now. Happy coding. 👩‍💻👨‍💻&lt;/p&gt;

&lt;p&gt;Cover image via Unsplash by &lt;a href="https://unsplash.com/@goran_ivos"&gt;Goran Ivos&lt;/a&gt;&lt;/p&gt;

</description>
      <category>bash</category>
      <category>productivity</category>
      <category>beginners</category>
      <category>terminal</category>
    </item>
    <item>
      <title>⚛️ Initiate a React app with multiple components on a single DOM element</title>
      <dc:creator>Nikita Hlopov</dc:creator>
      <pubDate>Mon, 09 Mar 2020 13:22:10 +0000</pubDate>
      <link>https://forem.com/visualcomposer/initiate-a-react-app-with-multiple-components-on-a-single-dom-element-2899</link>
      <guid>https://forem.com/visualcomposer/initiate-a-react-app-with-multiple-components-on-a-single-dom-element-2899</guid>
      <description>&lt;p&gt;In this article, I'll go through the use case of rendering multiple React components to a single DOM element of a React app.&lt;/p&gt;

&lt;p&gt;There might be a case when your app consists of independent components that might need to be initiated from different places on different conditions but inside a single container.&lt;/p&gt;

&lt;p&gt;Turns out that React can handle these cases with ease.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Initiate a generic React app&lt;/li&gt;
&lt;li&gt;Initiate a React app with multiple components&lt;/li&gt;
&lt;/ol&gt;

&lt;h2&gt;
  
  
  Initiate a generic React app
&lt;/h2&gt;

&lt;p&gt;Usually, the generic React app begins like so:&lt;/p&gt;

&lt;p&gt;HTML have a single &lt;code&gt;div&lt;/code&gt; container element:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight html"&gt;&lt;code&gt;&lt;span class="nt"&gt;&amp;lt;div&lt;/span&gt; &lt;span class="na"&gt;id=&lt;/span&gt;&lt;span class="s"&gt;"app"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&amp;lt;/div&amp;gt;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The React part is a &lt;strong&gt;single component&lt;/strong&gt; that gets rendered inside a given DOM container:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;appContainer&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nb"&gt;document&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;getElementById&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;app&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;

&lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nx"&gt;Form&lt;/span&gt; &lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;handleSubmit&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;e&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="nx"&gt;e&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;preventDefault&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt;
  &lt;span class="p"&gt;}&lt;/span&gt;
  &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="o"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nx"&gt;form&lt;/span&gt; &lt;span class="nx"&gt;onSubmit&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="nx"&gt;handleSubmit&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="o"&gt;&amp;gt;&lt;/span&gt;
    &lt;span class="o"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nx"&gt;input&lt;/span&gt; &lt;span class="nx"&gt;type&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;email&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt; &lt;span class="nx"&gt;placeholder&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;email@example.com&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt; &lt;span class="o"&gt;/&amp;gt;&lt;/span&gt;
    &lt;span class="o"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nx"&gt;input&lt;/span&gt; &lt;span class="nx"&gt;type&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;submit&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt; &lt;span class="nx"&gt;value&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;Submit&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt; &lt;span class="o"&gt;/&amp;gt;&lt;/span&gt;
  &lt;span class="o"&gt;&amp;lt;&lt;/span&gt;&lt;span class="sr"&gt;/form&amp;gt;&lt;/span&gt;&lt;span class="err"&gt;)
&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="nx"&gt;ReactDOM&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;render&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="o"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nx"&gt;Form&lt;/span&gt; &lt;span class="o"&gt;/&amp;gt;&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;appContainer&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  Initiate a React app with multiple components
&lt;/h2&gt;

&lt;p&gt;To initiate your app with multiple components you need to wrap them in a &lt;a href="https://reactjs.org/docs/fragments.html"&gt;React Fragment&lt;/a&gt; inside the &lt;code&gt;ReactDOM.render&lt;/code&gt; method.&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Fragments let you group a list of children without adding extra nodes to the DOM.&lt;br&gt;
&lt;/p&gt;
&lt;/blockquote&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;appContainer&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nb"&gt;document&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;getElementById&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;app&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;

&lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nx"&gt;Form&lt;/span&gt; &lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;handleSubmit&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;e&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="nx"&gt;e&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;preventDefault&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt;
  &lt;span class="p"&gt;}&lt;/span&gt;
  &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="o"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nx"&gt;form&lt;/span&gt; &lt;span class="nx"&gt;onSubmit&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="nx"&gt;handleSubmit&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="o"&gt;&amp;gt;&lt;/span&gt;
    &lt;span class="o"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nx"&gt;input&lt;/span&gt; &lt;span class="nx"&gt;type&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;email&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt; &lt;span class="nx"&gt;placeholder&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;email@example.com&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt; &lt;span class="o"&gt;/&amp;gt;&lt;/span&gt;
    &lt;span class="o"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nx"&gt;input&lt;/span&gt; &lt;span class="nx"&gt;type&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;submit&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt; &lt;span class="nx"&gt;value&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;Submit&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt; &lt;span class="o"&gt;/&amp;gt;&lt;/span&gt;
  &lt;span class="o"&gt;&amp;lt;&lt;/span&gt;&lt;span class="sr"&gt;/form&amp;gt;&lt;/span&gt;&lt;span class="err"&gt;)
&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nx"&gt;Content&lt;/span&gt; &lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="o"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nx"&gt;h2&lt;/span&gt;&lt;span class="o"&gt;&amp;gt;&lt;/span&gt;&lt;span class="nx"&gt;Subscribe&lt;/span&gt; &lt;span class="nx"&gt;to&lt;/span&gt; &lt;span class="nx"&gt;our&lt;/span&gt; &lt;span class="nx"&gt;newsletter&lt;/span&gt;&lt;span class="o"&gt;&amp;lt;&lt;/span&gt;&lt;span class="sr"&gt;/h2&lt;/span&gt;&lt;span class="err"&gt;&amp;gt;
&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="nx"&gt;ReactDOM&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;render&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;
  &lt;span class="o"&gt;&amp;lt;&amp;gt;&lt;/span&gt;
    &lt;span class="o"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nx"&gt;Content&lt;/span&gt; &lt;span class="o"&gt;/&amp;gt;&lt;/span&gt;
    &lt;span class="o"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nx"&gt;Form&lt;/span&gt; &lt;span class="o"&gt;/&amp;gt;&lt;/span&gt;
  &lt;span class="o"&gt;&amp;lt;&lt;/span&gt;&lt;span class="sr"&gt;/&amp;gt;, appContainer&lt;/span&gt;&lt;span class="err"&gt;)
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  Conclusion
&lt;/h2&gt;

&lt;p&gt;The good part about it is that you can wrap those components in a variable and render them based on a condition if necessary.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;formComponent&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="o"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nx"&gt;Form&lt;/span&gt; &lt;span class="o"&gt;/&amp;gt;&lt;/span&gt;
&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;contentComponent&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;isVisible&lt;/span&gt; &lt;span class="p"&gt;?&lt;/span&gt; &lt;span class="o"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nx"&gt;Content&lt;/span&gt; &lt;span class="o"&gt;/&amp;gt;&lt;/span&gt; &lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="kc"&gt;null&lt;/span&gt;

&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;components&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="o"&gt;&amp;lt;&amp;gt;&lt;/span&gt;
  &lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="nx"&gt;contentComponent&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;
  &lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="nx"&gt;formComponent&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="o"&gt;&amp;lt;&lt;/span&gt;&lt;span class="sr"&gt;/&lt;/span&gt;&lt;span class="err"&gt;&amp;gt;
&lt;/span&gt;
&lt;span class="nx"&gt;ReactDOM&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;render&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;components&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;appContainer&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;In a complex environment (ours is a WordPress plugin), it is a great way to control what gets delivered to the user.&lt;/p&gt;

&lt;p&gt;See full example on CodePen:&lt;br&gt;
&lt;iframe height="600" src="https://codepen.io/nikitahl/embed/gOpoOEj?height=600&amp;amp;default-tab=result&amp;amp;embed-version=2"&gt;
&lt;/iframe&gt;
&lt;/p&gt;

</description>
      <category>javascript</category>
      <category>react</category>
      <category>webdev</category>
      <category>beginners</category>
    </item>
    <item>
      <title>5 reasons to write Semantic HTML</title>
      <dc:creator>Nikita Hlopov</dc:creator>
      <pubDate>Wed, 04 Mar 2020 17:47:35 +0000</pubDate>
      <link>https://forem.com/visualcomposer/5-reasons-to-write-semantic-html-280f</link>
      <guid>https://forem.com/visualcomposer/5-reasons-to-write-semantic-html-280f</guid>
      <description>&lt;p&gt;I’ll go through a list of 5 reasons why web developers should pay more attention to semantic HTML.&lt;/p&gt;

&lt;p&gt;Another repost of my original article on the &lt;a href="https://nikitahl.com/why-it-is-important-to-write-semantic-html/"&gt;importance of writing semantic HTML&lt;/a&gt;&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Understandable code&lt;/li&gt;
&lt;li&gt;Screen readers&lt;/li&gt;
&lt;li&gt;Search engines (SEO)&lt;/li&gt;
&lt;li&gt;Usability (UX)&lt;/li&gt;
&lt;li&gt;Default styling&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;What does MDN say about Semantic HTML:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;In programming, Semantics refers to the meaning of a piece of code — for example ... "what purpose or role does that HTML element have" (rather than "what does it look like?".)&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;So the number one reason is:&lt;/p&gt;

&lt;h2&gt;
  
  
  1. Understandable code
&lt;/h2&gt;

&lt;p&gt;By giving meaning to your markup, you make it more understandable. From a human perspective semantic code is more readable, understandable and easier to maintain. Imagine looking at the code like this:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight html"&gt;&lt;code&gt;&lt;span class="nt"&gt;&amp;lt;div&lt;/span&gt; &lt;span class="na"&gt;id=&lt;/span&gt;&lt;span class="s"&gt;”brown-fox”&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;div&amp;gt;&lt;/span&gt;A story of quick brown fox&lt;span class="nt"&gt;&amp;lt;/div&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;div&amp;gt;&lt;/span&gt;The quick brown fox jumps over the lazy dog.&lt;span class="nt"&gt;&amp;lt;/div&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;div&amp;gt;&lt;/span&gt;Properties:&lt;span class="nt"&gt;&amp;lt;/div&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;div&amp;gt;&lt;/span&gt;- quick&lt;span class="nt"&gt;&amp;lt;/div&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;div&amp;gt;&lt;/span&gt;- brown&lt;span class="nt"&gt;&amp;lt;/div&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;div&amp;gt;&lt;/span&gt;- jumpy&lt;span class="nt"&gt;&amp;lt;/div&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;div&amp;gt;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The same structure but with meaningful tags:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight html"&gt;&lt;code&gt;&lt;span class="nt"&gt;&amp;lt;section&lt;/span&gt; &lt;span class="na"&gt;id=&lt;/span&gt;&lt;span class="s"&gt;”brown-fox”&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;h2&amp;gt;&lt;/span&gt;A story of quick brown fox&lt;span class="nt"&gt;&amp;lt;/h2&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;p&amp;gt;&lt;/span&gt;The quick brown fox jumps over the lazy dog.&lt;span class="nt"&gt;&amp;lt;/p&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;h3&amp;gt;&lt;/span&gt;Properties:&lt;span class="nt"&gt;&amp;lt;/h3&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;ul&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;li&amp;gt;&lt;/span&gt;quick&lt;span class="nt"&gt;&amp;lt;/li&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;li&amp;gt;&lt;/span&gt;brown&lt;span class="nt"&gt;&amp;lt;/li&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;&amp;lt;li&amp;gt;&lt;/span&gt;jumpy&lt;span class="nt"&gt;&amp;lt;/li&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;/ul&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;section&amp;gt;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;You can immediately spot the difference. Straight off the bat, you can tell what each part of the structure does.&lt;/p&gt;

&lt;h2&gt;
  
  
  2. Screen readers
&lt;/h2&gt;

&lt;p&gt;Not only humans (programmers) have the need to understand the meaning of the page structure, so do the machines, one of them are screen readers.&lt;/p&gt;

&lt;blockquote&gt;
  A screen reader is a form of assistive technology which is essential to people who are blind, as well as useful to people who are visually impaired, illiterate, or have a learning disability.   &lt;br&gt;
    —&lt;cite&gt;&lt;a href="https://en.wikipedia.org/wiki/Screen_reader"&gt;Wikipedia&lt;/a&gt;&lt;/cite&gt;
&lt;/blockquote&gt;

&lt;p&gt;A screen reader analyzes the contents of the web page and outputs the results via speech. This means whatever a screen reader sees, it will read. So it’s quite important to structurize your web page with a meaning. However modern screen readers are quite &lt;em&gt;“smart”&lt;/em&gt; and handle web pages very well.&lt;/p&gt;

&lt;p&gt;Both MAC and Windows have built-in screen readers. For MAC it is &lt;a href="https://www.apple.com/accessibility/mac/vision/"&gt;VoiceOver&lt;/a&gt;, for Windows it is &lt;a href="https://support.microsoft.com/en-us/help/22798/windows-10-complete-guide-to-narrator"&gt;Narrator&lt;/a&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  3. Search engines (SEO)
&lt;/h2&gt;

&lt;p&gt;Moving on from one machine type to another. The structure of your web page can affect SEO (Search Engine Optimization) results.&lt;/p&gt;

&lt;blockquote&gt;
  SEO stands for ‘Search Engine Optimization’. It’s the practice of optimizing your web pages to make them reach a high position in the search results of Google or other search engines.
    —&lt;cite&gt;&lt;a href="https://yoast.com/what-is-seo/"&gt;YOAST&lt;/a&gt;&lt;/cite&gt;
&lt;/blockquote&gt;

&lt;p&gt;However semantic HTML is not the primary factor that affects the SEO of the page, but it helps page &lt;a href="https://www.google.com/search/howsearchworks/crawling-indexing/"&gt;crawlers&lt;/a&gt; understand the structure of this page. A page with proper semantic HTML will have a chance to &lt;a href="https://www.inboundnow.com/html5-semantic-elements-mean-seo/"&gt;rank higher in the search results&lt;/a&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  4. Usability (UX)
&lt;/h2&gt;

&lt;p&gt;By using semantics not only you are aiding the machines, but you can also help people and make their lives better. The use of proper semantic HTML can boost up your website usability and accessibility. I think you all will agree with me, that you like resources that are intuitive and easy to use.&lt;/p&gt;

&lt;p&gt;Sometimes small adjustments or fine-tuning can make a huge difference for users. For instance, adding a &lt;code&gt;label&lt;/code&gt; element next to &lt;code&gt;input&lt;/code&gt;, or adding a proper attribute to the same &lt;code&gt;input&lt;/code&gt; element.&lt;/p&gt;

&lt;h2&gt;
  
  
  5. Default styling
&lt;/h2&gt;

&lt;p&gt;The good thing about semantic HTML, that elements come with default styling. Even without additional CSS the page that is built with proper semantic HTML will look good, be accessible and is going to provide the meaning and outline the structure.&lt;/p&gt;

&lt;p&gt;Even though the default styling can vary from browser to browser, the main look of the page will remain.&lt;/p&gt;

&lt;p&gt;Default styling comes to the rescue when something goes wrong and your CSS fails.&lt;/p&gt;

&lt;p&gt;Below I’ll share a list of resources I have found useful when I was learning about semantic HTML and Semantic Web in particular.&lt;/p&gt;

&lt;p&gt;Blogs:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;a href="https://codepen.io/mi-lee/post/an-overview-of-html5-semantics"&gt;https://codepen.io/mi-lee/post/an-overview-of-html5-semantics&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://internetingishard.com/html-and-css/forms/"&gt;https://internetingishard.com/html-and-css/forms/&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="http://html5doctor.com/lets-talk-about-semantics/"&gt;http://html5doctor.com/lets-talk-about-semantics/&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://stackoverflow.com/questions/17272019/why-to-use-html5-semantic-tag-instead-of-div"&gt;https://stackoverflow.com/questions/17272019/why-to-use-html5-semantic-tag-instead-of-div&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://webflow.com/blog/html5-semantic-elements-and-webflow-the-essential-guide"&gt;https://webflow.com/blog/html5-semantic-elements-and-webflow-the-essential-guide&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://www.dallasseogeek.com/uncategorized/understanding-semantic-html-and-its-applications-for-2015-and-beyond/#.WdRs79MjFTY"&gt;https://www.dallasseogeek.com/uncategorized/understanding-semantic-html-and-its-applications-for-2015-and-beyond/#.WdRs79MjFTY&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://www.smashingmagazine.com/2011/11/our-pointless-pursuit-of-semantic-value/"&gt;https://www.smashingmagazine.com/2011/11/our-pointless-pursuit-of-semantic-value/&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="http://html5doctor.com/microformats/"&gt;http://html5doctor.com/microformats/&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="http://html5doctor.com/microdata/"&gt;http://html5doctor.com/microdata/&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://www.lifewire.com/why-use-semantic-html-3468271"&gt;https://www.lifewire.com/why-use-semantic-html-3468271&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Docs:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;a href="https://en.wikipedia.org/wiki/Semantic_Web"&gt;https://en.wikipedia.org/wiki/Semantic_Web&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://developers.google.com/web/fundamentals/native-hardware/click-to-call/"&gt;https://developers.google.com/web/fundamentals/native-hardware/click-to-call/&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://developers.google.com/web/fundamentals/accessibility/semantics-builtin/"&gt;https://developers.google.com/web/fundamentals/accessibility/semantics-builtin/&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="http://microformats.org/wiki/html5"&gt;http://microformats.org/wiki/html5&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://developer.mozilla.org/en-US/docs/Web/HTML/Element/time"&gt;https://developer.mozilla.org/en-US/docs/Web/HTML/Element/time&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://www.w3.org/RDF/FAQ"&gt;https://www.w3.org/RDF/FAQ&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://www.w3.org/2006/Talks/0718-aaai-tbl/Overview.html#(1)"&gt;https://www.w3.org/2006/Talks/0718-aaai-tbl/Overview.html#(1)&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://medium.com/virtuoso-blog/a-semantic-web-artificial-intelligence-ea480b8f4507"&gt;https://medium.com/virtuoso-blog/a-semantic-web-artificial-intelligence-ea480b8f4507&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA"&gt;https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://www.w3.org/TR/rdfa-primer/"&gt;https://www.w3.org/TR/rdfa-primer/&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="http://schema.org/docs/about.html"&gt;http://schema.org/docs/about.html&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="http://rdfa.info/"&gt;http://rdfa.info/&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://developer.mozilla.org/en-US/docs/Glossary/Semantics#Semantics_in_HTML"&gt;https://developer.mozilla.org/en-US/docs/Glossary/Semantics#Semantics_in_HTML&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Videos:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;a href="https://www.youtube.com/watch?v=qvONd7Z8vec"&gt;https://www.youtube.com/watch?v=qvONd7Z8vec&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://www.youtube.com/watch?v=z9_rdtdA2BQ"&gt;https://www.youtube.com/watch?v=z9_rdtdA2BQ&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://www.youtube.com/watch?v=OGg8A2zfWKg"&gt;https://www.youtube.com/watch?v=OGg8A2zfWKg&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;

</description>
      <category>html</category>
      <category>webdev</category>
      <category>beginners</category>
    </item>
    <item>
      <title>Do you even use CSS floats these days 🤔</title>
      <dc:creator>Nikita Hlopov</dc:creator>
      <pubDate>Thu, 20 Feb 2020 09:22:22 +0000</pubDate>
      <link>https://forem.com/nikitahl/do-you-even-use-css-floats-these-days-5g11</link>
      <guid>https://forem.com/nikitahl/do-you-even-use-css-floats-these-days-5g11</guid>
      <description>&lt;p&gt;I was wondering if anyone is still using CSS &lt;code&gt;float&lt;/code&gt; property today?&lt;br&gt;
If so what's the reason or possible application for that?&lt;/p&gt;

</description>
      <category>discuss</category>
    </item>
    <item>
      <title>Feedback for a project</title>
      <dc:creator>Nikita Hlopov</dc:creator>
      <pubDate>Wed, 05 Feb 2020 16:13:20 +0000</pubDate>
      <link>https://forem.com/nikitahl/feedback-for-a-project-36o8</link>
      <guid>https://forem.com/nikitahl/feedback-for-a-project-36o8</guid>
      <description>&lt;p&gt;I'd like to ask a community for a feedback on a little project I've made a while ago.&lt;br&gt;
It's a small web app to generate CSS theme &lt;a href="https://nikitahl.github.io/css-base/"&gt;https://nikitahl.github.io/css-base/&lt;/a&gt;. Does it make any sense? Can someone actually benefit from it or get some sort of a value from it, or it's just a useless tool.&lt;br&gt;
Please be honest.&lt;br&gt;
Thanks.&lt;/p&gt;

</description>
      <category>help</category>
      <category>feedback</category>
      <category>review</category>
    </item>
    <item>
      <title>Cool Chrome Dev Tools tricks and tips you might not know about</title>
      <dc:creator>Nikita Hlopov</dc:creator>
      <pubDate>Tue, 04 Feb 2020 21:05:15 +0000</pubDate>
      <link>https://forem.com/nikitahl/cool-chrome-dev-tools-tricks-and-tips-you-might-not-know-about-56oe</link>
      <guid>https://forem.com/nikitahl/cool-chrome-dev-tools-tricks-and-tips-you-might-not-know-about-56oe</guid>
      <description>&lt;p&gt;Google Chrome browser has been my favorite browser for development for quite some time. And the Dev Tools capabilities is one of the reasons for that.&lt;/p&gt;

&lt;p&gt;This article is a repost of the one I've made a year ago on my own blog - &lt;a href="https://nikitahl.com/cool-chrome-dev-tools-tricks-you-might-not-know-about/"&gt;Cool Chrome Dev Tools tricks and tips you might not know about&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;Below you will find a list of cool tricks and tips I've found in Chrome Dev Tools over the years.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Dev Tools theme&lt;/li&gt;
&lt;li&gt;Dev Tools panel layout&lt;/li&gt;
&lt;li&gt;Switch between Dev Tools panels&lt;/li&gt;
&lt;li&gt;Switch between CSS properties&lt;/li&gt;
&lt;li&gt;Toggle element visibility&lt;/li&gt;
&lt;li&gt;Edit element attributes&lt;/li&gt;
&lt;li&gt;Search DOM tree&lt;/li&gt;
&lt;li&gt;Add devices&lt;/li&gt;
&lt;li&gt;Add new styles shortcut&lt;/li&gt;
&lt;li&gt;Edit any text content on the page&lt;/li&gt;
&lt;li&gt;Store value as a global variable in console&lt;/li&gt;
&lt;li&gt;Increment CSS values&lt;/li&gt;
&lt;li&gt;DOM elements as global variables&lt;/li&gt;
&lt;li&gt;Switch between color formats&lt;/li&gt;
&lt;li&gt;Return the value of the last expression evaluated in the console&lt;/li&gt;
&lt;li&gt;Bonus: Expand all sub-properties of an object that's been logged to the console&lt;/li&gt;
&lt;/ol&gt;

&lt;h2&gt;
  
  
  1. Dev Tools theme
&lt;/h2&gt;

&lt;p&gt;There's a way to toggle between Light and Dark theme for Dev Tools. Inside &lt;em&gt;Settings&lt;/em&gt; under &lt;em&gt;Appearance&lt;/em&gt; choose between Light and Dark themes.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--kqVVxPTJ--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://nikitahl.com/images/dev-tools/dev-tools-theme.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--kqVVxPTJ--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://nikitahl.com/images/dev-tools/dev-tools-theme.png" alt="Dev Tools theme" title="Dev Tools theme" width="722" height="165"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  2. Dev Tools panel layout
&lt;/h2&gt;

&lt;p&gt;In some cases, it is more comfortable to work with a certain type of panel layout.&lt;br&gt;
You can select between three possible layouts:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;horizontal;&lt;/li&gt;
&lt;li&gt;vertical;&lt;/li&gt;
&lt;li&gt;auto.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;It can be set inside &lt;em&gt;Settings&lt;/em&gt; under &lt;em&gt;Appearance&lt;/em&gt;.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--DhS-Nw0i--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://nikitahl.com/images/dev-tools/dev-tools-layout.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--DhS-Nw0i--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://nikitahl.com/images/dev-tools/dev-tools-layout.png" alt="Dev Tools panel layout" title="Dev Tools panel layout" width="722" height="168"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  3. Switch between Dev Tools panels
&lt;/h2&gt;

&lt;p&gt;There's an easy way to switch between Dev Tools panels via keyboard.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
cmd + ]/[ for MAC;&lt;/li&gt;
&lt;li&gt;
ctrl + ]/[ for Windows and Linux.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--xwZa3qR6--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_66%2Cw_880/https://nikitahl.com/images/dev-tools/dev-tools-panels.gif" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--xwZa3qR6--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_66%2Cw_880/https://nikitahl.com/images/dev-tools/dev-tools-panels.gif" alt="Dev Tools panel switch" title="Dev Tools panel switch" width="728" height="60"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  4. Switching between CSS properties
&lt;/h2&gt;

&lt;p&gt;While in the &lt;em&gt;Styles&lt;/em&gt; panel click on the CSS property and press:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
tab to jump to the next property;&lt;/li&gt;
&lt;li&gt;
tab + shift to jump to the previous property.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--GonWVJQe--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_66%2Cw_880/https://nikitahl.com/images/dev-tools/switch-css-props.gif" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--GonWVJQe--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_66%2Cw_880/https://nikitahl.com/images/dev-tools/switch-css-props.gif" alt="Switching between CSS properties" title="Switching between CSS properties" width="728" height="90"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  5. Toggle element visibility
&lt;/h2&gt;

&lt;p&gt;You can easily toggle element visibility inside element DOM tree by pressing h key on selected element.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--hQguxd_e--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_66%2Cw_880/https://nikitahl.com/images/dev-tools/hide-element.gif" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--hQguxd_e--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_66%2Cw_880/https://nikitahl.com/images/dev-tools/hide-element.gif" alt="Toggle element visibility" title="Toggle element visibility" width="728" height="90"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  6. Edit element attributes
&lt;/h2&gt;

&lt;p&gt;Inside element DOM tree press enter key on the selected element to edit attribute. Press tab to edit next attribute, press tab + shift edit previous attribute.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--7DvKIagh--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_66%2Cw_880/https://nikitahl.com/images/dev-tools/edit-element-attrs.gif" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--7DvKIagh--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_66%2Cw_880/https://nikitahl.com/images/dev-tools/edit-element-attrs.gif" alt="Edit element attributes" title="Edit element attributes" width="728" height="90"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  7. Search DOM tree
&lt;/h2&gt;

&lt;p&gt;To find any attribute, element, content or any other string inside DOM tree just press:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
cmd + f for MAC;&lt;/li&gt;
&lt;li&gt;
ctrl + f for Windows and Linux.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--1VWMZKmo--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://nikitahl.com/images/dev-tools/dom-tree-search.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--1VWMZKmo--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://nikitahl.com/images/dev-tools/dom-tree-search.png" alt="Search DOM tree" title="Search DOM tree" width="729" height="160"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  8. Add devices
&lt;/h2&gt;

&lt;p&gt;You can enable/disable existing devices or add a custom device inside &lt;em&gt;Device toolbar&lt;/em&gt;.&lt;br&gt;
Inside &lt;em&gt;Settings&lt;/em&gt; click on the &lt;em&gt;Devices&lt;/em&gt; tab. You will see a list of existing devices where you can enable/disable devices. Or you can add a new one by clicking on the &lt;em&gt;Add custom device...&lt;/em&gt; button.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--V7HBS6YL--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://nikitahl.com/images/dev-tools/add-custom-device.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--V7HBS6YL--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://nikitahl.com/images/dev-tools/add-custom-device.png" alt="Add devices" title="Add devices" width="729" height="304"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  9. Add new styles shortcut
&lt;/h2&gt;

&lt;p&gt;To quickly add a new style like:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Color;&lt;/li&gt;
&lt;li&gt;Background color;&lt;/li&gt;
&lt;li&gt;Text-shadow;&lt;/li&gt;
&lt;li&gt;Box-shadow.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Hover over a small icon ( &lt;strong&gt;⋮&lt;/strong&gt; ) in the bottom left corner and the above options will appear.&lt;br&gt;
To insert a new style rule below click on the &lt;strong&gt;+&lt;/strong&gt; icon.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--t25riHhi--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_66%2Cw_880/https://nikitahl.com/images/dev-tools/add-styles-shortcut.gif" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--t25riHhi--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_66%2Cw_880/https://nikitahl.com/images/dev-tools/add-styles-shortcut.gif" alt="Add new styles shortcut" title="Add new styles shortcut" width="728" height="92"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  10. Edit any text content on the page
&lt;/h2&gt;

&lt;p&gt;In the console write &lt;code&gt;document.designMode = "on"&lt;/code&gt; and you will be able to edit any text content on the page instantly.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--udvJOfpT--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://nikitahl.com/images/dev-tools/document-design-mode.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--udvJOfpT--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://nikitahl.com/images/dev-tools/document-design-mode.png" alt="Document Design Mode" title="Document Design Mode" width="729" height="105"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  11. Store value as a global variable in console
&lt;/h2&gt;

&lt;p&gt;Any returned data of &lt;em&gt;object&lt;/em&gt; or &lt;em&gt;function&lt;/em&gt; type can be stored as a global variable in the console. E.g. &lt;code&gt;console.log(['a', 'b'])&lt;/code&gt; will return an array. Right click on it and select &lt;strong&gt;Store as a global variable&lt;/strong&gt; which will be accessible via &lt;code&gt;temp1&lt;/code&gt; keyword in the console.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Note:&lt;/strong&gt; These variables are temporary and are only available during the current session, meaning after page refresh they will be gone.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--BapunTTc--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_66%2Cw_880/https://nikitahl.com/images/dev-tools/store-as-a-global-variable.gif" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--BapunTTc--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_66%2Cw_880/https://nikitahl.com/images/dev-tools/store-as-a-global-variable.gif" alt="Store value as a global variable" title="Store value as a global variable" width="728" height="171"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  12. Increment CSS values
&lt;/h2&gt;

&lt;p&gt;Numeric CSS values can easily be incremented and decremented by using certain key combinations:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Increment value by 1 ↑;&lt;/li&gt;
&lt;li&gt;Dcrement value by 1 ↓;&lt;/li&gt;
&lt;li&gt;Increment value by 0.1 alt + ↑;&lt;/li&gt;
&lt;li&gt;Dcrement value by 0.1 alt + ↓;&lt;/li&gt;
&lt;li&gt;Increment value by 10 shift + ↑;&lt;/li&gt;
&lt;li&gt;Dcrement value by 10 shift + ↓;&lt;/li&gt;
&lt;li&gt;Increment value by 100 cmd + ↑ (MAC), ctrl + ↑ (Windows and Linux);&lt;/li&gt;
&lt;li&gt;Dcrement value by 100 cmd + ↓ (MAC),  ctrl + ↓ (Windows and Linux).&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--7c6ndUNc--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_66%2Cw_880/https://nikitahl.com/images/dev-tools/increment-value.gif" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--7c6ndUNc--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_66%2Cw_880/https://nikitahl.com/images/dev-tools/increment-value.gif" alt="Increment CSS values" title="Increment CSS values" width="728" height="92"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  13. DOM elements as global variables
&lt;/h2&gt;

&lt;p&gt;A DOM element can be stored and accessed as a global variable in the console. In the DOM tree right click on the element tag and click &lt;strong&gt;Store as a global variable&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Note:&lt;/strong&gt; These variables are temporary and are only available during the current session, meaning after page refresh they will be gone.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--NG0mVHys--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://nikitahl.com/images/dev-tools/store-element-as-global-variable.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--NG0mVHys--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://nikitahl.com/images/dev-tools/store-element-as-global-variable.png" alt="DOM elements as global variables" title="DOM elements as global variables" width="728" height="345"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  14. Switch between color formats
&lt;/h2&gt;

&lt;p&gt;You can easily change the color format by holding shift key and click on the &lt;strong&gt;Color Preview&lt;/strong&gt; box next to the value.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--PfvFjRbe--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_66%2Cw_880/https://nikitahl.com/images/dev-tools/switch-color-formats.gif" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--PfvFjRbe--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_66%2Cw_880/https://nikitahl.com/images/dev-tools/switch-color-formats.gif" alt="Switch between color formats" title="Switch between color formats" width="728" height="78"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  15. Return the value of the last expression evaluated in the console
&lt;/h2&gt;

&lt;p&gt;&lt;code&gt;$_&lt;/code&gt; in the Console returns the value of the last expression evaluated.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--UqvgMOJw--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://nikitahl.com/images/dev-tools/last-evaluated-expression.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--UqvgMOJw--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://nikitahl.com/images/dev-tools/last-evaluated-expression.png" alt="Return last evaluated expression" title="Return last evaluated expression" width="729" height="103"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Bonus: Expand all sub-properties of an object that's been logged to the console
&lt;/h2&gt;

&lt;p&gt;Once the object is logged, hold alt key and click expand &lt;strong&gt;▸&lt;/strong&gt; icon.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--uxyDFArH--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_66%2Cw_880/https://nikitahl.com/images/dev-tools/expand-props.gif" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--uxyDFArH--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_66%2Cw_880/https://nikitahl.com/images/dev-tools/expand-props.gif" alt="Expand all sub-properties" title="Expand all sub-properties" width="728" height="554"&gt;&lt;/a&gt;&lt;/p&gt;

</description>
      <category>webdev</category>
      <category>codenewbie</category>
      <category>beginners</category>
      <category>devtools</category>
    </item>
    <item>
      <title>Writing and debugging Cypress tests</title>
      <dc:creator>Nikita Hlopov</dc:creator>
      <pubDate>Thu, 30 Jan 2020 22:36:49 +0000</pubDate>
      <link>https://forem.com/visualcomposer/writing-and-debugging-cypress-tests-1cii</link>
      <guid>https://forem.com/visualcomposer/writing-and-debugging-cypress-tests-1cii</guid>
      <description>&lt;p&gt;I want to share the knowledge I and my team gained after implementing Cypress e2e tests in our project.&lt;/p&gt;

&lt;h2&gt;
  
  
  Intro
&lt;/h2&gt;

&lt;p&gt;About a year ago we've (&lt;a href="https://github.com/visualcomposer/builder/" rel="noopener noreferrer"&gt;Visual Composer dev team&lt;/a&gt;) picked Cypress as our main tool for e2e tests. It was a new experience for the whole team as none of us was familiar with e2e testing. Over that period of time not only we've covered a large amount of functionality with tests but also we've learned quite a bit.&lt;/p&gt;

&lt;p&gt;Recently I've made a small demo for our team of developers to summarise what we already know. The purpose of this demo was to:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Share knowledge and to establish common understanding and principles for e2e tests among all developers in our team&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;That inspired me to write an article.&lt;/p&gt;

&lt;h2&gt;
  
  
  Outline
&lt;/h2&gt;

&lt;p&gt;Conventionally we can split the app testing process into two parts:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;writing tests - when a developer actually writes the code&lt;/li&gt;
&lt;li&gt;debugging tests - fixing issues when the test is failing&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;So that's what I'm going to share with you in a form of tips and solutions.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;NOTE: Even though our product may be very specific I think these tips can be applicable to a wide variety of projects.&lt;/strong&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Writing tests
&lt;/h2&gt;

&lt;p&gt;These tips helped me to write tests and to tackle issues faster and with ease.&lt;/p&gt;

&lt;h3&gt;
  
  
  1. Cypress syntax is similar to jQuery
&lt;/h3&gt;

&lt;p&gt;If you know jQuery then understanding that Cypress commands are similar to the jQuery counterparts like &lt;em&gt;selectors&lt;/em&gt; and &lt;em&gt;chaining&lt;/em&gt; will make your Cypress learning curve much smoother.&lt;/p&gt;

&lt;p&gt;E.g. the &lt;code&gt;cy.get()&lt;/code&gt; command will return a collection of elements. Knowing that you'll be able to handle further chaining or resolve the possible error.&lt;/p&gt;

&lt;h3&gt;
  
  
  2. Cypress is lacking some features
&lt;/h3&gt;

&lt;p&gt;Some of the functionality cannot be tested like &lt;code&gt;hover&lt;/code&gt; effect or testing within and &lt;code&gt;iframe&lt;/code&gt;.&lt;/p&gt;

&lt;p&gt;The good part is that the Cypress team is aware of that and communicating to the community on possible solutions and workarounds.&lt;/p&gt;

&lt;h3&gt;
  
  
  3. Cypress resources
&lt;/h3&gt;

&lt;p&gt;Continuing the thought from the previous point, I really like &lt;a href="https://docs.cypress.io/" rel="noopener noreferrer"&gt;Cypress API documentation&lt;/a&gt; and their &lt;a href="https://github.com/cypress-io/cypress/issues" rel="noopener noreferrer"&gt;GitHub repo's Issues&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;I was able to resolve almost every problem just by checking their docs or searching GitHub issues. Stackoverflow helped me as well. 😅&lt;/p&gt;

&lt;p&gt;Overall I find the Cypress team quite engaging and willing to help. &lt;/p&gt;

&lt;h3&gt;
  
  
  4. Folder structure
&lt;/h3&gt;

&lt;p&gt;We are sticking to the recommended folder and file structure in the official &lt;a href="https://docs.cypress.io/guides/references/configuration.html#Folders-Files" rel="noopener noreferrer"&gt;Cypress docs&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;Since our project is quite large and multiple components that need to be tested are stored in multiple repositories, having a unified structure helps a lot.&lt;/p&gt;

&lt;h3&gt;
  
  
  5. Cypress strange behavior
&lt;/h3&gt;

&lt;p&gt;In our case sometimes Cypress may render duplicate elements. I'm not sure if this is a project-specific issue, but I couldn't find any information on that topic.&lt;/p&gt;

&lt;p&gt;The point is if a specific issue is occurring in your tests, you need to share that information across your team and prepare a solution for such cases.&lt;/p&gt;

&lt;p&gt;Btw, the solution to our issue is since we're only checking the single element we're adding an index with a bracket notation to select the first element.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="nx"&gt;cy&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;get&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;.vce-row-content&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;)[&lt;/span&gt;&lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt;
  &lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;children&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt;
  &lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;should&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;have.length&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="mi"&gt;3&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  6. CSS values are computed values
&lt;/h3&gt;

&lt;p&gt;When checking for CSS values it's important to understand that Cypress will compare your assertion to a computed CSS value. That is equal to the one you get when using the &lt;code&gt;getComputedStyle()&lt;/code&gt; method.&lt;/p&gt;

&lt;h2&gt;
  
  
  Debugging
&lt;/h2&gt;

&lt;p&gt;We separate debugging into two types.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Local&lt;/li&gt;
&lt;li&gt;Pipeline&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Local debugging
&lt;/h3&gt;

&lt;p&gt;Usually, it's quite simple but sometimes developers get stuck and having a hard time resolving the issue. Even though the Cypress itself helps to troubleshoot.&lt;/p&gt;

&lt;h4&gt;
  
  
  1. Carefully read the error message
&lt;/h4&gt;

&lt;p&gt;Developers are in a hurry and don't read the error message till the very end or read it superficially.&lt;/p&gt;

&lt;p&gt;Sometimes it may contain a clue or a possible solution.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fpbs.twimg.com%2Fmedia%2FEFI-sskXoAUc-Ri%3Fformat%3Dpng%26name%3D900x900" class="article-body-image-wrapper"&gt;&lt;img alt="Cypress error message" src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fpbs.twimg.com%2Fmedia%2FEFI-sskXoAUc-Ri%3Fformat%3Dpng%26name%3D900x900"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h4&gt;
  
  
  2. Additional data in the console
&lt;/h4&gt;

&lt;p&gt;To retrieve additional data click on the step and the data will be outputted in the console.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fraw.githubusercontent.com%2Fnikitahl%2Fimages-from-e2e-testing%2Fmaster%2Fcypress-pinned-step.png" class="article-body-image-wrapper"&gt;&lt;img alt="Cypress console error message" src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fraw.githubusercontent.com%2Fnikitahl%2Fimages-from-e2e-testing%2Fmaster%2Fcypress-pinned-step.png"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h4&gt;
  
  
  3. Comment out commands
&lt;/h4&gt;

&lt;p&gt;Comment out commands to get to the problem point faster. We have quite complex logic behind our tests, so they take quite a long time to run. In order to make the debugging process faster, I use that technique.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="cm"&gt;/* global describe, it, cy */&lt;/span&gt;

&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;ELEMENT_NAME&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;Text Block&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;

&lt;span class="nf"&gt;describe&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;ELEMENT_NAME&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nf"&gt;function &lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nf"&gt;it&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;Adds element to the page, checks automatically added elements, checks attributes&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nf"&gt;function &lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="nx"&gt;cy&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;fixture&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;../fixtures/textBlock.json&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;).&lt;/span&gt;&lt;span class="nf"&gt;then&lt;/span&gt;&lt;span class="p"&gt;((&lt;/span&gt;&lt;span class="nx"&gt;settings&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
      &lt;span class="nx"&gt;cy&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;createPage&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt;
      &lt;span class="nx"&gt;cy&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;addElement&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;ELEMENT_NAME&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;

      &lt;span class="c1"&gt;// cy.setTinyMce({&lt;/span&gt;
      &lt;span class="c1"&gt;//   title: 'Content',&lt;/span&gt;
      &lt;span class="c1"&gt;//   text: settings.text,&lt;/span&gt;
      &lt;span class="c1"&gt;//   elementType: {&lt;/span&gt;
      &lt;span class="c1"&gt;//     name: settings.elementType.name&lt;/span&gt;
      &lt;span class="c1"&gt;//   },&lt;/span&gt;
      &lt;span class="c1"&gt;//   alignment: {&lt;/span&gt;
      &lt;span class="c1"&gt;//     name: settings.alignment.name&lt;/span&gt;
      &lt;span class="c1"&gt;//   }&lt;/span&gt;
      &lt;span class="c1"&gt;// })&lt;/span&gt;

      &lt;span class="nx"&gt;cy&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;setClassAndId&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;settings&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;customId&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;settings&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;customClass&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;

      &lt;span class="c1"&gt;// cy.setDO(settings.designOptions)&lt;/span&gt;

      &lt;span class="nx"&gt;cy&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;savePage&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt;
      &lt;span class="nx"&gt;cy&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;viewPage&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt;

      &lt;span class="nx"&gt;cy&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;get&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;.vce-text-block&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
        &lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;should&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;have.class&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;settings&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;customClass&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
        &lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;should&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;have.attr&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;id&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;settings&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;customId&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;or go straight ahead to the exact page (our tests generate site pages in WordPress)&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="cm"&gt;/* global describe, it, cy */&lt;/span&gt;

&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;ELEMENT_NAME&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;Text Block&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;

&lt;span class="nf"&gt;describe&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;ELEMENT_NAME&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nf"&gt;function &lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nf"&gt;it&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;Adds element to the page, checks automatically added elements, checks attributes&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nf"&gt;function &lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="nx"&gt;cy&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;fixture&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;../fixtures/textBlock.json&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;).&lt;/span&gt;&lt;span class="nf"&gt;then&lt;/span&gt;&lt;span class="p"&gt;((&lt;/span&gt;&lt;span class="nx"&gt;settings&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
      &lt;span class="c1"&gt;// cy.createPage()&lt;/span&gt;
      &lt;span class="c1"&gt;// cy.addElement(ELEMENT_NAME)&lt;/span&gt;

      &lt;span class="c1"&gt;// cy.setTinyMce({&lt;/span&gt;
      &lt;span class="c1"&gt;//   title: 'Content',&lt;/span&gt;
      &lt;span class="c1"&gt;//   text: settings.text,&lt;/span&gt;
      &lt;span class="c1"&gt;//   elementType: {&lt;/span&gt;
      &lt;span class="c1"&gt;//     name: settings.elementType.name&lt;/span&gt;
      &lt;span class="c1"&gt;//   },&lt;/span&gt;
      &lt;span class="c1"&gt;//   alignment: {&lt;/span&gt;
      &lt;span class="c1"&gt;//     name: settings.alignment.name&lt;/span&gt;
      &lt;span class="c1"&gt;//   }&lt;/span&gt;
      &lt;span class="c1"&gt;// })&lt;/span&gt;

      &lt;span class="c1"&gt;// cy.setClassAndId(settings.customId, settings.customClass)&lt;/span&gt;

      &lt;span class="c1"&gt;// cy.setDO(settings.designOptions)&lt;/span&gt;

      &lt;span class="c1"&gt;// cy.savePage()&lt;/span&gt;
      &lt;span class="c1"&gt;// cy.viewPage()&lt;/span&gt;

      &lt;span class="nx"&gt;cy&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;visit&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;http://localhost:8888/wp/auto-draft-4&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;

      &lt;span class="nx"&gt;cy&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;get&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;.vce-text-block&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
        &lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;should&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;have.class&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;settings&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;customClass&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
        &lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;should&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;have.attr&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;id&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;settings&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;customId&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Pipeline debugging
&lt;/h3&gt;

&lt;p&gt;We use two different environments to run Cypress on the pipeline:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;CircleCI&lt;/strong&gt; on GitHub for our main project&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Gitlab CI&lt;/strong&gt; on GitLab for other projects&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;They both basically do the same stuff, the main difference is the interface.&lt;/p&gt;

&lt;p&gt;On pipeline we use Docker image with:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Apache server&lt;/li&gt;
&lt;li&gt;Pre-installed WordPress&lt;/li&gt;
&lt;li&gt;Pre-installed theme&lt;/li&gt;
&lt;li&gt;Pre-installed plugins&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Debugging on the pipeline is essentially similar to a local.&lt;/p&gt;

&lt;h4&gt;
  
  
  1. Read the error message
&lt;/h4&gt;

&lt;p&gt;Like in the Local debugging read the error, half of the times it will be enough. The image below is the error message from the GitLab CI terminal.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fraw.githubusercontent.com%2Fnikitahl%2Fimages-from-e2e-testing%2Fmaster%2Fgitlab-terminal-error.png" class="article-body-image-wrapper"&gt;&lt;img alt="GitLab CI terminal error message" src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fraw.githubusercontent.com%2Fnikitahl%2Fimages-from-e2e-testing%2Fmaster%2Fgitlab-terminal-error.png"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h4&gt;
  
  
  2. See artifacts (screenshot or video)
&lt;/h4&gt;

&lt;p&gt;By default Cypress have screenshots enabled, but we also enabled video recording. To improve performance a little, we've enabled video recording only on failure. Video recording can be enabled in the &lt;code&gt;cypress.json&lt;/code&gt; config file:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight json"&gt;&lt;code&gt;&lt;span class="nl"&gt;"video"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="kc"&gt;true&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Once the test is failed now we can check a screenshot or a video.&lt;/p&gt;

&lt;p&gt;Artifacts on GitLab CI:&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fraw.githubusercontent.com%2Fnikitahl%2Fimages-from-e2e-testing%2Fmaster%2Fgitlab-artifacts.png" class="article-body-image-wrapper"&gt;&lt;img alt="GitLab CI artifacts" src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fraw.githubusercontent.com%2Fnikitahl%2Fimages-from-e2e-testing%2Fmaster%2Fgitlab-artifacts.png"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Artifacts on CircleCI:&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fraw.githubusercontent.com%2Fnikitahl%2Fimages-from-e2e-testing%2Fmaster%2Fcircleci-artifacts.png" class="article-body-image-wrapper"&gt;&lt;img alt="CircleCI artifacts" src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fraw.githubusercontent.com%2Fnikitahl%2Fimages-from-e2e-testing%2Fmaster%2Fcircleci-artifacts.png"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h4&gt;
  
  
  3. Plugins for debugging
&lt;/h4&gt;

&lt;p&gt;The following plugins can be used both locally and on the pipeline. We're saving up resources and using them rarely only for intricate cases. For the most part, it's enough with error messages and artifacts, but it's good to know that such plugins exist.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;Saves the Cypress test command log as a JSON file if a test fails &lt;a href="https://github.com/bahmutov/cypress-failed-log" rel="noopener noreferrer"&gt;https://github.com/bahmutov/cypress-failed-log&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;A Cypress plugin that sends all logs that occur in the browser to stdout in the terminal &lt;a href="https://github.com/flotwig/cypress-log-to-output" rel="noopener noreferrer"&gt;https://github.com/flotwig/cypress-log-to-output&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Inner docs
&lt;/h2&gt;

&lt;p&gt;If your team or project has an inner knowledge base or even if you don't, start documenting. Over time there's just too much information piling in the heads of developers.&lt;/p&gt;

&lt;p&gt;We've begun documenting &lt;em&gt;howtos&lt;/em&gt; and practices on e2e testing. That way all developers now have a point of reference.&lt;/p&gt;

&lt;p&gt;You don't have to scale to full-blown documentation at once. Start with a single document and a few code snippets. 😉&lt;/p&gt;

&lt;h2&gt;
  
  
  Conclusion
&lt;/h2&gt;

&lt;p&gt;These are the techniques we use to write the e2e tests. I do hope that people can draw from our knowledge and improve their testing. Let us know what techniques and methods you are using by replying in the comments.&lt;/p&gt;

&lt;p&gt;Check out our tests they are available in our &lt;a href="https://github.com/VisualComposer/builder" rel="noopener noreferrer"&gt;GitHub repo&lt;/a&gt;.&lt;/p&gt;

</description>
      <category>testing</category>
      <category>cypress</category>
      <category>javascript</category>
      <category>webdev</category>
    </item>
    <item>
      <title>9 Practical tips for beginner web developers</title>
      <dc:creator>Nikita Hlopov</dc:creator>
      <pubDate>Mon, 09 Dec 2019 18:46:53 +0000</pubDate>
      <link>https://forem.com/nikitahl/9-practical-tips-for-beginner-web-developers-49ah</link>
      <guid>https://forem.com/nikitahl/9-practical-tips-for-beginner-web-developers-49ah</guid>
      <description>&lt;p&gt;This is a list of 9 practical tips for beginner developers by a developer who was a beginner once as well.&lt;/p&gt;

&lt;p&gt;This post is actually a repost of my &lt;a href="https://nikitahl.com/practical-tips-for-beginner-web-developers/"&gt;original one&lt;/a&gt; I've made a while ago on my blog.&lt;/p&gt;

&lt;p&gt;These days there is plenty of information around to start a career as a developer. In this article I just want to share tips from my own experience that I found useful when I was learning.&lt;/p&gt;

&lt;p&gt;I hope that someone might find it useful and learn something new.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
Coding courses/school;&lt;/li&gt;
&lt;li&gt;
Online coding courses/school;&lt;/li&gt;
&lt;li&gt;
Resources/study materials;&lt;/li&gt;
&lt;li&gt;
Code editors;&lt;/li&gt;
&lt;li&gt;
Command line/Terminal;&lt;/li&gt;
&lt;li&gt;
Online tools/services;&lt;/li&gt;
&lt;li&gt;
&lt;a href="https://dev.tobrowser-dev-tools"&gt;Browser Dev Tools&lt;/a&gt;;&lt;/li&gt;
&lt;li&gt;
Local server;&lt;/li&gt;
&lt;li&gt;
Social Media.&lt;/li&gt;
&lt;/ol&gt;

&lt;h2&gt;
  
  
  Coding courses/school
&lt;/h2&gt;

&lt;p&gt;In my opinion, this is the best way to start. I've enrolled at a local coding school after learning by myself for some time.&lt;/p&gt;

&lt;p&gt;The main advantage over all other methods is that you get a real life experience and mentoring from the teachers.&lt;/p&gt;

&lt;p&gt;You can ask a question any time during a seminar, engage in the discussion, learn from and share experience with other students.&lt;/p&gt;

&lt;p&gt;The teachers will not only tell you basic stuff but will also give valuable tips and pieces of advice how to improve yourself, share their own experience, tell stories from real life.&lt;/p&gt;

&lt;p&gt;Overall, if you have the possibility I strongly recommend you to start by taking a real-life course on development.&lt;/p&gt;

&lt;h2&gt;
  
  
  Online coding courses/school
&lt;/h2&gt;

&lt;p&gt;During my learning period, I've also been taking a few online courses. Actually, I do this to this date.&lt;/p&gt;

&lt;p&gt;The cool part about it is that unlike the real-life coding courses/school, which most probably will have fixed study hours and location, you can attend it at any time and from anywhere your comfortable with.&lt;/p&gt;

&lt;p&gt;Also, you can rewatch the video or go through an exercise over time.&lt;/p&gt;

&lt;p&gt;Online courses tend to constantly update study material, so you'll always be up to date to new technologies and practices.&lt;/p&gt;

&lt;p&gt;Most of these online courses have online communities where students share experience and ask questions.&lt;/p&gt;

&lt;h2&gt;
  
  
  Resources/study materials
&lt;/h2&gt;

&lt;p&gt;If you're not taking courses/school of any kind, there are plenty of ways to get information online. Today you can find literally tons of information on almost any topic.&lt;/p&gt;

&lt;p&gt;From my own experience what I use and can recommend is:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;a href="https://developer.mozilla.org/"&gt;MDN&lt;/a&gt; - all time favorite and ultimate resource I refer up to this day (they have tutotials for beginners);&lt;/li&gt;
&lt;li&gt;
&lt;a href="https://caniuse.com/"&gt;Can I use&lt;/a&gt; - mostly for checking browser compatibility;&lt;/li&gt;
&lt;li&gt;
&lt;a href="https://stackoverflow.com/"&gt;StackOverflow&lt;/a&gt; - ask/search question for custom cases, but be aware that some answers may not be suitable or quite accurate for your case.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Resources I don't use on a daily basis, but is worth mentioning:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;a href="https://htmlreference.io/"&gt;htmlreference.io&lt;/a&gt; - a list of all the HTML tags and attributes;&lt;/li&gt;
&lt;li&gt;
&lt;a href="https://cssreference.io/"&gt;cssreference.io&lt;/a&gt; - a list of all the CSS properties;&lt;/li&gt;
&lt;li&gt;
&lt;a href="http://es6-features.org"&gt;ECMAScript 6 Features&lt;/a&gt; - ES6 features and examples;&lt;/li&gt;
&lt;li&gt;
&lt;a href="http://youmightnotneedjquery.com/"&gt;youmightnotneedjquery&lt;/a&gt; - consider using Vanilla JS over jQuery when possible.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;And lastly the Youtube. For a quick explanation or a tutorial, Youtube is the perfect spot. Lots of interesting and useful videos out there.&lt;/p&gt;

&lt;h2&gt;
  
  
  Code editors
&lt;/h2&gt;

&lt;p&gt;You'll be writing a lot of code, so a proper code editor is a must. The code editor can make a big difference when you're writing a code. It will ease your life as a developer by helping easily navigate and edit code.&lt;/p&gt;

&lt;p&gt;I've tried quite a few, each one of them has its own pros and cons. But I'm not going to make a comparison now, as this article isn't about that. I'm just going to list my favorite ones (all of them are FREE).&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;a href="https://atom.io/"&gt;Atom&lt;/a&gt;;&lt;/li&gt;
&lt;li&gt;
&lt;a href="https://www.sublimetext.com/"&gt;Sublime text&lt;/a&gt;;&lt;/li&gt;
&lt;li&gt;
&lt;a href="https://code.visualstudio.com/"&gt;Visual Studio Code&lt;/a&gt;;&lt;/li&gt;
&lt;li&gt;
&lt;a href="http://brackets.io/"&gt;Brackets&lt;/a&gt;.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;There are plenty of articles comparing code editors, and I encourage you to read them, but I suggest try them out as many as you can, and in time you'll find your favorite.&lt;/p&gt;

&lt;h2&gt;
  
  
  Command line/Terminal
&lt;/h2&gt;

&lt;p&gt;Along with the web development technologies the command line experience is a must for a modern developer.&lt;/p&gt;

&lt;p&gt;A lot of work will be dependant on the command line (e.g. &lt;a href="https://git-scm.com/"&gt;git&lt;/a&gt;), as well as some technologies require you to have a command line knowledge.&lt;/p&gt;

&lt;p&gt;If you're not familiar with the command line just yet, don't be intimidated, it's not that hard. Take your time and just practice, read tutorials and watch a few video explanations, its plenty out there.&lt;/p&gt;

&lt;p&gt;There will be roughly only up to 10 commands that you'll have to memorize. For everything else there's Google. ;)&lt;/p&gt;

&lt;h2&gt;
  
  
  Online tools/services
&lt;/h2&gt;

&lt;p&gt;Services like &lt;a href="https://github.com"&gt;Github&lt;/a&gt; and &lt;a href="https://codepen.io"&gt;Codepen&lt;/a&gt; does not only help you on your journey of becoming a web developer but also can serve as your own business card or a portfolio if you wish.&lt;/p&gt;

&lt;p&gt;With the help of such services you can:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;share your own code and projects with people;&lt;/li&gt;
&lt;li&gt;see other people's code and projects (and learn from them);&lt;/li&gt;
&lt;li&gt;collaborate with other developers;&lt;/li&gt;
&lt;li&gt;engage in discussions;&lt;/li&gt;
&lt;li&gt;get your code reviewed;&lt;/li&gt;
&lt;li&gt;get inspired;&lt;/li&gt;
&lt;li&gt;inspire others;&lt;/li&gt;
&lt;li&gt;improve your creativity;&lt;/li&gt;
&lt;li&gt;contribute to the &lt;strong&gt;Open Source&lt;/strong&gt; community.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Getting a &lt;em&gt;Github&lt;/em&gt; account is a good start, you can:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;understand what is &lt;a href="https://en.wikipedia.org/wiki/Version_control"&gt;version control&lt;/a&gt;;&lt;/li&gt;
&lt;li&gt;learn more about the command line;&lt;/li&gt;
&lt;li&gt;get familiar with one of the most popular service for developers.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Browser Dev Tools
&lt;/h2&gt;

&lt;p&gt;Being a web developer is not only about writing code or working with the command line. But also debugging! That said you should be proficient with browser's Dev Tool or Developer Tools.&lt;/p&gt;

&lt;p&gt;You can start by opening a Dev Tools in your browser and just begin clicking and exploring.&lt;/p&gt;

&lt;p&gt;With Dev Tools you can:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Inspect and edit DOM elements;&lt;/li&gt;
&lt;li&gt;Inspect and edit element styles;&lt;/li&gt;
&lt;li&gt;View messages and run JavaScript from the Console;&lt;/li&gt;
&lt;li&gt;Debug JavaScript;&lt;/li&gt;
&lt;li&gt;View and debug network activity.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;And that's just some of the thing you can do there's much more.&lt;/p&gt;

&lt;p&gt;Each browser's Dev Tools has its own traits, but for the most part, they're all the same.&lt;br&gt;
My favorite browser to work with is Chrome. They have an awesome Dev Tools &lt;em&gt;imho&lt;/em&gt; which they constantly update and maintain, as well as they have a complete documentation on &lt;a href="https://developers.google.com/web/tools/chrome-devtools/"&gt;Dev Tools&lt;/a&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  Local server
&lt;/h2&gt;

&lt;p&gt;It's a common practice to test your code locally right in the browser. But I strongly advise you to install a local server for testing purposes.&lt;/p&gt;

&lt;p&gt;You'll get an experience of how your code actually works in an environment close to real one.&lt;br&gt;
You'll need a local server:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;for testing purposes;&lt;/li&gt;
&lt;li&gt;to make AJAX calls;&lt;/li&gt;
&lt;li&gt;if you're planning to learn any of the server-side languages.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;A couple of the most popular local servers:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;a href="https://www.mamp.info/en/"&gt;MAMP&lt;/a&gt; (Mac and Widows);&lt;/li&gt;
&lt;li&gt;
&lt;a href="https://www.apachefriends.org/"&gt;XAMPP&lt;/a&gt; (Mac, Windows, Linux).&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Social Media
&lt;/h2&gt;

&lt;p&gt;Being a developer also means that you constantly have to learn and improve yourself. That is why the final tip is - get a Twitter account and follow developers, software companies/blogs/groups/communities. It's an easy way to always be up to date with current technologies and trends.&lt;/p&gt;

&lt;p&gt;Never stop learning.&lt;/p&gt;

</description>
      <category>beginners</category>
      <category>webdev</category>
    </item>
    <item>
      <title>5 HTML tags you should consider using more often</title>
      <dc:creator>Nikita Hlopov</dc:creator>
      <pubDate>Tue, 26 Nov 2019 22:42:37 +0000</pubDate>
      <link>https://forem.com/nikitahl/5-html-tags-you-should-consider-using-more-often-mm</link>
      <guid>https://forem.com/nikitahl/5-html-tags-you-should-consider-using-more-often-mm</guid>
      <description>&lt;p&gt;When writing HTML developers often use common tags like &lt;code&gt;div&lt;/code&gt;, &lt;code&gt;section&lt;/code&gt;, &lt;code&gt;p&lt;/code&gt;, &lt;code&gt;span&lt;/code&gt; and that's ok.&lt;/p&gt;

&lt;p&gt;But to give your markup more meaning (make it more &lt;strong&gt;semantic&lt;/strong&gt;) I suggest you start using following tags more often. So instead of plain old &lt;code&gt;div&lt;/code&gt;s and &lt;code&gt;span&lt;/code&gt;s try:&lt;/p&gt;

&lt;h2&gt;
  
  
  1. &lt;code&gt;address&lt;/code&gt;
&lt;/h2&gt;

&lt;p&gt;Use this tag whenever you need to wrap the contact information or a contact address.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight html"&gt;&lt;code&gt;&lt;span class="nt"&gt;&amp;lt;address&amp;gt;&lt;/span&gt;
  150 Deansgate,&lt;span class="nt"&gt;&amp;lt;br&amp;gt;&lt;/span&gt;
  Manchester M3 3EH,&lt;span class="nt"&gt;&amp;lt;br&amp;gt;&lt;/span&gt;
  United Kingdom
&lt;span class="nt"&gt;&amp;lt;/address&amp;gt;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This tag may also include:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;any type of contact information that is needed, such as a physical address, URL, email address, phone number, social media handle, geographic coordinates, and so forth. - &lt;a href="https://developer.mozilla.org/en-US/docs/Web/HTML/Element/address"&gt;MDN&lt;/a&gt;&lt;/p&gt;
&lt;/blockquote&gt;

&lt;h2&gt;
  
  
  2. &lt;code&gt;del&lt;/code&gt;
&lt;/h2&gt;

&lt;p&gt;To mark the content that has been deleted from the document use &lt;a href="https://developer.mozilla.org/en-US/docs/Web/HTML/Element/del"&gt;&lt;code&gt;del&lt;/code&gt;&lt;/a&gt;. This element comes with the default &lt;code&gt;strike-through&lt;/code&gt; styling.&lt;/p&gt;

&lt;p&gt;One of the most common uses for this element I found to be is displaying prices.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight html"&gt;&lt;code&gt;&lt;span class="nt"&gt;&amp;lt;p&amp;gt;&lt;/span&gt;
  The item is sold out &lt;span class="nt"&gt;&amp;lt;del&amp;gt;&lt;/span&gt;19.95$&lt;span class="nt"&gt;&amp;lt;/del&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/p&amp;gt;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Often this element can be seen along side its counterpart ...&lt;/p&gt;

&lt;h2&gt;
  
  
  3. &lt;code&gt;ins&lt;/code&gt;
&lt;/h2&gt;

&lt;p&gt;It is used to show that the content has been added to the document instead.&lt;/p&gt;

&lt;p&gt;Again nice example with prices, &lt;a href="https://developer.mozilla.org/en-US/docs/Web/HTML/Element/ins"&gt;&lt;code&gt;ins&lt;/code&gt;&lt;/a&gt; is the new price here:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight html"&gt;&lt;code&gt;&lt;span class="nt"&gt;&amp;lt;p&amp;gt;&lt;/span&gt;
  The item is on sale only &lt;span class="nt"&gt;&amp;lt;ins&amp;gt;&lt;/span&gt;9.95$&lt;span class="nt"&gt;&amp;lt;/ins&amp;gt;&lt;/span&gt; &lt;span class="nt"&gt;&amp;lt;del&amp;gt;&lt;/span&gt;19.95$&lt;span class="nt"&gt;&amp;lt;/del&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/p&amp;gt;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  4. &lt;code&gt;small&lt;/code&gt;
&lt;/h2&gt;

&lt;p&gt;This tag is used to define &lt;em&gt;side-comments and small print&lt;/em&gt;. The contents of the &lt;a href="https://developer.mozilla.org/en-US/docs/Web/HTML/Element/small"&gt;&lt;code&gt;small&lt;/code&gt;&lt;/a&gt; tag is usually have smaller &lt;code&gt;font-size&lt;/code&gt; style by default. One of the uses is to wrap copyright or legal text in the footer.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight html"&gt;&lt;code&gt;&lt;span class="nt"&gt;&amp;lt;footer&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;p&amp;gt;&lt;/span&gt;Yoursitename&lt;span class="nt"&gt;&amp;lt;/p&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;small&amp;gt;&lt;/span&gt;Copyright © 2019&lt;span class="nt"&gt;&amp;lt;/small&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/footer&amp;gt;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  5. &lt;code&gt;time&lt;/code&gt;
&lt;/h2&gt;

&lt;p&gt;Finally this tag is used to display specific time or date. Often &lt;a href="https://developer.mozilla.org/en-US/docs/Web/HTML/Element/time"&gt;&lt;code&gt;time&lt;/code&gt;&lt;/a&gt; tag comes along with the &lt;code&gt;datetime&lt;/code&gt; attribute which &lt;em&gt;indicates the time and/or date&lt;/em&gt;.&lt;/p&gt;

&lt;p&gt;Often is used to display published post date and time.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight html"&gt;&lt;code&gt;&lt;span class="nt"&gt;&amp;lt;p&amp;gt;&lt;/span&gt;
  Published on &lt;span class="nt"&gt;&amp;lt;time&lt;/span&gt; &lt;span class="na"&gt;datetime=&lt;/span&gt;&lt;span class="s"&gt;"2019-11-27T00:30"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;November 27, 2019&lt;span class="nt"&gt;&amp;lt;/time&amp;gt;&lt;/span&gt;.
&lt;span class="nt"&gt;&amp;lt;/p&amp;gt;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



</description>
      <category>html</category>
    </item>
  </channel>
</rss>
