<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: nikolisan</title>
    <description>The latest articles on DEV Community by nikolisan (@nikolisan).</description>
    <link>https://dev.to/nikolisan</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%2F107549%2Fd2ca0ddd-1404-4208-8902-988b0ea644f4.png</url>
      <title>DEV Community: nikolisan</title>
      <link>https://dev.to/nikolisan</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/nikolisan"/>
    <language>en</language>
    <item>
      <title>Creating graphics with CSS</title>
      <dc:creator>nikolisan</dc:creator>
      <pubDate>Tue, 16 Oct 2018 15:14:21 +0000</pubDate>
      <link>https://dev.to/nikolisan/creating-graphics-with-css-48f</link>
      <guid>https://dev.to/nikolisan/creating-graphics-with-css-48f</guid>
      <description>&lt;p&gt;Sometime ago I started learning about web development. As a beginner I started with HTML and CSS. I watched several videos and read several articles on the web. I was always excited with the animations and the smart graphics presented on the websites and I was curious about how I could create them.&lt;/p&gt;

&lt;p&gt;Then I saw a great &lt;a href="https://dev.to/aspittel/learning-css-through-creating-art-54c0"&gt;video&lt;/a&gt; Ali made and I was eager to create a simple CSS graphic with animation. The first thing that came to my mind was a gift card like those we shared back when internet was not a thing yet.&lt;/p&gt;

&lt;h3&gt;
  
  
  So, let's make a simple gift card to share with your valentine.
&lt;/h3&gt;

&lt;p&gt;The main idea is to create a heart and below to present a love message. For this I will use a &lt;code&gt;div&lt;/code&gt; for the heart and a &lt;code&gt;div&lt;/code&gt; for the message.&lt;/p&gt;

&lt;h4&gt;
  
  
  Heart modelling
&lt;/h4&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--nuyKruuN--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://bit.ly/2yH2VF3" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--nuyKruuN--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://bit.ly/2yH2VF3" alt="heart-mock" title="Heart mockup"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;The heart consists of three shapes. A square and two circles. It is possible to create the heart shape using only a &lt;code&gt;div&lt;/code&gt; block and the two pseudo-elements &lt;code&gt;::before&lt;/code&gt; and &lt;code&gt;::after&lt;/code&gt;.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight"&gt;&lt;pre class="highlight css"&gt;&lt;code&gt;&lt;span class="nc"&gt;.heart&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;width&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;100px&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;height&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;100px&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;background&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;#EF9A9A&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;transform&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;rotate&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="m"&gt;45deg&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="nc"&gt;.heart&lt;/span&gt;&lt;span class="nd"&gt;::after&lt;/span&gt;&lt;span class="o"&gt;,&lt;/span&gt;
&lt;span class="nc"&gt;.heart&lt;/span&gt;&lt;span class="nd"&gt;::before&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;position&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;absolute&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;content&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;''&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;width&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;100px&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;height&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;100px&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;background&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;#EF9A9A&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;border-radius&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;50%&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;border-top&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;5px&lt;/span&gt; &lt;span class="m"&gt;#E57373&lt;/span&gt; &lt;span class="nb"&gt;solid&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="nc"&gt;.heart&lt;/span&gt;&lt;span class="nd"&gt;::after&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;top&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;-55px&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="nc"&gt;.heart&lt;/span&gt;&lt;span class="nd"&gt;::before&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;top&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;-5px&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;left&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;-50px&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;Using &lt;strong&gt;CSS&lt;/strong&gt; I created three squares and to make two of those (the &lt;code&gt;::before&lt;/code&gt; and &lt;code&gt;::after&lt;/code&gt;) circles I used &lt;code&gt;border-radius: 50%&lt;/code&gt;. Then I carefully position them to create the shape I'm looking for.&lt;/p&gt;
&lt;h5&gt;
  
  
  The next step is to create a heartbeat-like effect.&lt;br&gt;
&lt;/h5&gt;

&lt;p&gt;At the &lt;code&gt;.heart&lt;/code&gt; class I create an infinite animation, animating the scale of the element.&lt;br&gt;
&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre class="highlight css"&gt;&lt;code&gt;&lt;span class="nc"&gt;.heart&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;animation&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;heart-beat&lt;/span&gt; &lt;span class="m"&gt;2s&lt;/span&gt; &lt;span class="n"&gt;ease-in-out&lt;/span&gt; &lt;span class="n"&gt;infinite&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="k"&gt;@keyframes&lt;/span&gt; &lt;span class="n"&gt;heart-beat&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="err"&gt;50&lt;/span&gt;&lt;span class="o"&gt;%&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="nl"&gt;transform&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;rotate&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="m"&gt;45deg&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="n"&gt;scale&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="m"&gt;0.8&lt;/span&gt;&lt;span class="p"&gt;);&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;The heart then is completed. I did some further styling and the result you can see it below.&lt;br&gt;
&lt;iframe height="600" src="https://codepen.io/nikolisan/embed/qJpjdK?height=600&amp;amp;default-tab=result&amp;amp;embed-version=2"&gt;
&lt;/iframe&gt;
&lt;/p&gt;

&lt;p&gt;&lt;em&gt;PS:&lt;/em&gt; I could use three &lt;code&gt;div&lt;/code&gt;s to create the shape of the heart and position them in the same manner. I thought it would be awesome if I could practise using the pseudo-elements.&lt;/p&gt;
&lt;h3&gt;
  
  
  Birthday cake animation
&lt;/h3&gt;

&lt;p&gt;I was pretty satisfied with the result of heart animation and I thought that it would be the best moment to try and recreate a shape I've seen before in github.&lt;br&gt;
&lt;/p&gt;
&lt;div class="ltag-github-readme-tag"&gt;
  &lt;div class="readme-overview"&gt;
    &lt;h2&gt;
      &lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--vJ70wriM--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://practicaldev-herokuapp-com.freetls.fastly.net/assets/github-logo-ba8488d21cd8ee1fee097b8410db9deaa41d0ca30b004c0c63de0a479114156f.svg" alt="GitHub logo"&gt;
      &lt;a href="https://github.com/elenatorro"&gt;
        elenatorro
      &lt;/a&gt; / &lt;a href="https://github.com/elenatorro/CSSCake"&gt;
        CSSCake
      &lt;/a&gt;
    &lt;/h2&gt;
    &lt;h3&gt;
      Birthday Cake made with CSS
    &lt;/h3&gt;
  &lt;/div&gt;
  &lt;div class="ltag-github-body"&gt;
    
&lt;div id="readme" class="md"&gt;
&lt;h1&gt;
CSS Birthday Cake&lt;/h1&gt;
&lt;p&gt;Birthday Cake made with CSS.&lt;/p&gt;
&lt;/div&gt;

  &lt;/div&gt;
  &lt;div class="gh-btn-container"&gt;&lt;a class="gh-btn" href="https://github.com/elenatorro/CSSCake"&gt;View on GitHub&lt;/a&gt;&lt;/div&gt;
&lt;/div&gt;



&lt;p&gt;I gave it a go following the same concept as above and the end result is listed below.&lt;br&gt;
&lt;iframe height="600" src="https://codepen.io/nikolisan/embed/BqJdGr?height=600&amp;amp;default-tab=result&amp;amp;embed-version=2"&gt;
&lt;/iframe&gt;
&lt;/p&gt;

&lt;p&gt;&lt;em&gt;I hope you like my article as it is my first full article here. Any tips, advice or whatever is really appreciated.&lt;/em&gt;&lt;/p&gt;

</description>
      <category>css</category>
      <category>animations</category>
      <category>showdev</category>
    </item>
    <item>
      <title>Fullstack development using JS</title>
      <dc:creator>nikolisan</dc:creator>
      <pubDate>Fri, 12 Oct 2018 18:42:10 +0000</pubDate>
      <link>https://dev.to/nikolisan/fullstack-development-using-js-458j</link>
      <guid>https://dev.to/nikolisan/fullstack-development-using-js-458j</guid>
      <description>&lt;p&gt;I have a question for you today and it's a general purpose one. I want to learn more about the modern web development. I've watched many tutorials and courses online but as I search more and more, I get confused even more.&lt;/p&gt;

&lt;p&gt;I will describe my main question through an example. I want to create a web application which displays data retrieved from a DB, which is populated with some sensor values.&lt;/p&gt;

&lt;p&gt;I've seen many online lessons creating this kind of an app using React.js and other using Express.js or pure Node.js. I understand that the React is for the frontend and the Express is for the backend. However similar things can be made using both frameworks.&lt;/p&gt;

&lt;p&gt;Using the Express.js I can create a server side application which handles the the requests to the DB's API, handles the routing between pages and can handle HTTP requests and generate EJS templates to show the data to the screen. My question is where does React come and help to the production of the app, especially when the rendering is done from the client and not on the server (which makes things worse for SEO).&lt;/p&gt;

</description>
    </item>
  </channel>
</rss>
