<?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: Georgi Kotov</title>
    <description>The latest articles on DEV Community by Georgi Kotov (@kotov).</description>
    <link>https://dev.to/kotov</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%2F464899%2F1b79bb0a-5542-4a3d-92e7-e30f01aee2ea.jpeg</url>
      <title>DEV Community: Georgi Kotov</title>
      <link>https://dev.to/kotov</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/kotov"/>
    <language>en</language>
    <item>
      <title>Node.js Dev Environment Setup</title>
      <dc:creator>Georgi Kotov</dc:creator>
      <pubDate>Mon, 17 Oct 2022 15:57:21 +0000</pubDate>
      <link>https://dev.to/kotov/initial-environment-setup-1o63</link>
      <guid>https://dev.to/kotov/initial-environment-setup-1o63</guid>
      <description>&lt;h2&gt;
  
  
  Pre-requisites - Lab exercises
&lt;/h2&gt;

&lt;h3&gt;
  
  
  Use Personal Laptops
&lt;/h3&gt;

&lt;p&gt;It's &lt;strong&gt;strongly recommended&lt;/strong&gt; that you use personal laptop during exercises. &lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Security , so you don't accidentally expose personal credentials (e.g. Github). &lt;/li&gt;
&lt;li&gt;Your code and changes might be wiped off on the lab computer.&lt;/li&gt;
&lt;/ol&gt;

&lt;h3&gt;
  
  
  Setup Github account and Git CLI
&lt;/h3&gt;

&lt;ol&gt;
&lt;li&gt;Setup a &lt;a href="https://github.com"&gt;Github account&lt;/a&gt; beforehand and install Git CLI following the &lt;a href="https://git-scm.com/book/en/v2/Getting-Started-Installing-Git"&gt;instructions&lt;/a&gt; and login to the CLI with your Github account.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Easiest way to do that is to&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Create Github repo from your account&lt;/li&gt;
&lt;li&gt;Using &lt;code&gt;git clone&lt;/code&gt; command create local copy of the repository.&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Create some &lt;code&gt;dummy.txt&lt;/code&gt; file and run the following commands: &lt;/p&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;git add -u dummy.txt
git commit -m "feat(dummy): my cool dummy commit"
git push -u origin main
&lt;/code&gt;&lt;/pre&gt;
&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Verify changes are pushed to your Github repo.&lt;/p&gt;&lt;/li&gt;
&lt;/ol&gt;




&lt;h2&gt;
  
  
  Installing IDE
&lt;/h2&gt;

&lt;p&gt;I strongly recommend installing &lt;a href="https://code.visualstudio.com/download"&gt;Visual Studio Code&lt;/a&gt; due to the wide community and support, as well as for the amazing plugins. Unless you are not used to use something else for Node like Webstorm, Sublime or other go with VS Code.&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Kind request: Do everyone a favour and please use dark theme on your IDE.&lt;/em&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Node Version Manager (Optional)
&lt;/h2&gt;

&lt;p&gt;It's sometimes required to be able to toggle between different versions of Node due to dependencies or project specific requirements hence use version manager.  &lt;/p&gt;

&lt;h3&gt;
  
  
  Libraries
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;a href="https://github.com/nvm-sh/nvm"&gt;nvm&lt;/a&gt; - Linux/MacOS&lt;/li&gt;
&lt;li&gt;
&lt;a href="https://github.com/tj/n"&gt;n&lt;/a&gt; - Linux/MacOS&lt;/li&gt;
&lt;li&gt;
&lt;a href="https://github.com/coreybutler/nvm-windows"&gt;nvm-windows&lt;/a&gt; - used for Windows&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Installation and verification with NVM
&lt;/h3&gt;

&lt;p&gt;After installing the CLI, make sure you install and use the LTS version of Node (currently 16.18).&lt;/p&gt;

&lt;p&gt;With &lt;code&gt;nvm&lt;/code&gt; you do that by the following:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Run &lt;code&gt;nvm i --lts&lt;/code&gt;
&lt;/li&gt;
&lt;li&gt;Run &lt;code&gt;nvm use --lts&lt;/code&gt;
&lt;/li&gt;
&lt;li&gt;You need to reload any old CLI windows such as Terminal (Linux) or Command Prompt/PowerShell (Windows)&lt;/li&gt;
&lt;li&gt;Open a new Terminal or Command Prompt and run &lt;code&gt;node -v&lt;/code&gt; you should get the lates node version printed out.&lt;/li&gt;
&lt;/ol&gt;

&lt;h2&gt;
  
  
  Node Installation (Simple)
&lt;/h2&gt;

&lt;p&gt;You can install Node.js without NVM using plain installation.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;To install on Windows or MacOS users download the LTS version from &lt;a href="https://nodejs.org/en/"&gt;here&lt;/a&gt; and follow the steps throughout installer.&lt;/li&gt;
&lt;li&gt;For Linux distros you can use the respective package managers such as &lt;code&gt;apt&lt;/code&gt; for Ubuntu.&lt;/li&gt;
&lt;/ol&gt;

&lt;h3&gt;
  
  
  Running your first Node.js program
&lt;/h3&gt;

&lt;ol&gt;
&lt;li&gt;Download the following &lt;a href="https://gist.github.com/MrKotov/3690757b95ba93a8b79744f58b800b9b"&gt;gist&lt;/a&gt; and save to file name &lt;code&gt;server.js&lt;/code&gt; on your local machine.&lt;/li&gt;
&lt;li&gt;Open a Terminal or Command Prompt/PowerShell CLI and navigate to the directory of the &lt;code&gt;server.js&lt;/code&gt; file.&lt;/li&gt;
&lt;li&gt;Execute &lt;code&gt;node server.js&lt;/code&gt; with optional argument for port (e.g. in case 3001 is used, run &lt;code&gt;node server.js 3002&lt;/code&gt;).
You should get success message in your console &lt;code&gt;"Hello World" Node Server running at http://127.0.0.1:3001&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;Open &lt;code&gt;http:127.0.0.1:3001&lt;/code&gt; in your browser. You should see the following JSON response &lt;code&gt;{ success: true, message: "Hello world!" }&lt;/code&gt;
&lt;/li&gt;
&lt;/ol&gt;

&lt;h2&gt;
  
  
  Congrats you are a Web Developer now! The rest is copy-pasting from StackOverflow!
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--zLmn_jFC--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/pmbmesauyezgs2vl521b.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--zLmn_jFC--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/pmbmesauyezgs2vl521b.png" alt="congrats" width="455" height="290"&gt;&lt;/a&gt;&lt;/p&gt;

</description>
      <category>webdev</category>
      <category>node</category>
      <category>beginners</category>
      <category>programming</category>
    </item>
    <item>
      <title>TU-Sofia Masters - Web Dev Lab Exercises</title>
      <dc:creator>Georgi Kotov</dc:creator>
      <pubDate>Mon, 17 Oct 2022 15:47:36 +0000</pubDate>
      <link>https://dev.to/kotov/tu-sofiia-maghistri-20222023-4o76</link>
      <guid>https://dev.to/kotov/tu-sofiia-maghistri-20222023-4o76</guid>
      <description>&lt;h2&gt;
  
  
  Introduction
&lt;/h2&gt;

&lt;p&gt;In the series &lt;em&gt;&lt;a href="https://dev.to/kotov/series/20167"&gt;Web Development&lt;/a&gt;&lt;/em&gt; I will upload articles related to Web Development course for TU - Sofia Lab Exercises. &lt;/p&gt;




&lt;h2&gt;
  
  
  Въведение
&lt;/h2&gt;

&lt;p&gt;В серията &lt;em&gt;&lt;a href="https://dev.to/kotov/series/20167"&gt;Порграмиране за интернет&lt;/a&gt;&lt;/em&gt; ще се качват статии свързани с Програмиране за интернет за ТУ - София Лабораторни упражнения.&lt;/p&gt;

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