<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[Code Lounge]]></title><description><![CDATA[Code lounge brings you all the DEV news and information]]></description><link>https://codelounge.dev</link><image><url>https://cdn.hashnode.com/res/hashnode/image/upload/v1617260051606/wkVPHg52e.png</url><title>Code Lounge</title><link>https://codelounge.dev</link></image><generator>RSS for Node</generator><lastBuildDate>Mon, 11 May 2026 02:26:30 GMT</lastBuildDate><atom:link href="https://codelounge.dev/rss.xml" rel="self" type="application/rss+xml"/><language><![CDATA[en]]></language><ttl>60</ttl><item><title><![CDATA[Build A Stunning Generative AI App with a React IDE]]></title><description><![CDATA[If you've ever wondered how AI applications generate images from user prompts, you've come to the right place.
In this article, you will learn how these tools work by building an AI application to generate images.
Create the application
We'll start b...]]></description><link>https://codelounge.dev/build-a-stunning-generative-ai-app-with-a-react-ide</link><guid isPermaLink="true">https://codelounge.dev/build-a-stunning-generative-ai-app-with-a-react-ide</guid><category><![CDATA[React]]></category><category><![CDATA[Web Development]]></category><category><![CDATA[Programming Blogs]]></category><category><![CDATA[JavaScript]]></category><dc:creator><![CDATA[Catalin Pit]]></dc:creator><pubDate>Mon, 20 Nov 2023 09:35:31 GMT</pubDate><enclosure url="https://cdn.hashnode.com/res/hashnode/image/upload/v1700472885028/bd8893ad-72dc-40b2-854f-c92bc11bcf7d.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>If you've ever wondered how AI applications generate images from user prompts, you've come to the right place.</p>
<p>In this article, you will learn how these tools work by building an AI application to generate images.</p>
<h2 id="heading-create-the-application">Create the application</h2>
<p>We'll start by creating a React + TypeScript application using Vite. Run the following command in your terminal:</p>
<pre><code class="lang-plaintext">npm create vite@latest
</code></pre>
<p>You'll then have to answer three questions so Vite understands how to configure your project.</p>
<pre><code class="lang-plaintext">✔ Project name: aimages
✔ Select a framework: › React
✔ Select a variant: › TypeScript
</code></pre>
<p>Lastly, you need to install and configure TailwindCSS.</p>
<p>Run the 2 commands below (in that order). The first command installs <code>tailwindcss</code> and its peer dependencies. The second command generates the <code>tailwind.config.js</code> and <code>postcss.config.js</code> files.</p>
<pre><code class="lang-plaintext">npm install -D tailwindcss postcss autoprefixer

npx tailwindcss init -p
</code></pre>
<p>Now open the <code>tailwind.config.js</code> file and modify the code as follows:</p>
<pre><code class="lang-plaintext">/** @type {import('tailwindcss').Config} */
export default {
  content: [
    "./index.html",
    "./src/**/*.{js,ts,jsx,tsx}",
  ],
  theme: {
    extend: {},
  },
  plugins: [],
}
</code></pre>
<p>The above code configures TailwindCSS, specifying which files the framework should scan for class usage. It's set to check the <code>index.html</code> file and any JavaScript or TypeScript files in the <code>src</code> directory. It also lets you customize the theme, colors, fonts, and many other things.</p>
<p>Lastly, open <code>/src/styles.css</code> and add the TailwindCSS directives at the top of the file:</p>
<pre><code class="lang-plaintext">@tailwind base;
@tailwind components;
@tailwind utilities;
</code></pre>
<p>You're done with the project configuration! Now, upload the project on GitHub before proceeding to the next stage. You'll see later why!</p>
<h2 id="heading-the-problem-with-building-user-interfaces">The problem with building user interfaces</h2>
<p>Before going further, let's highlight the main issues with building user interfaces.</p>
<p>One of the main issues with building user interfaces is that you don't have live visual feedback when building them. You make the changes in your editor, save them, and preview them in the browser. Then, if you're not happy with the changes, you have to repeat the process.</p>
<p>That results in a lot of switching between the IDE and the browser. While it might seem like a minor inconvenience, those seconds of waiting for the browser to refresh, plus the mental shift required, add up over time. Over the course of a day, this switching results in a substantial amount of wasted time.</p>
<p>It also results in a break of flow. Every disruption (like switching between applications) breaks the flow, leading to longer task completion times and possibly more errors.</p>
<p>On top of that, collaborating with others can be tedious and time-consuming. The usual way of collaborating involves working on the app, pushing the changes to GitHub, and deploying them. Only after that can the other collaborators check your work. That results in a substantial amount of time lost on unproductive things, such as waiting for the changes to deploy. So, the traditional approach can be quite cumbersome and inefficient.</p>
<p>In this article, you'll see a complementary tool you can use with your favorite IDE to build user interfaces better and faster.</p>
<h2 id="heading-a-visual-react-ide">A visual React IDE</h2>
<p><a target="_blank" href="https://codux.hopp.to/catalin">Codux</a> is a free visual IDE for React + TypeScript applications. It enables you to work on the projects in real-time through a visual editor. All the changes you make to the component's properties, styles, and structure (JSX) are reflected automatically on the screen.</p>
<blockquote>
<p>Important mention: Codux is <strong>not meant to replace</strong> your favourite IDE. It's a complementary tool that you can use alongside your IDE.</p>
</blockquote>
<p>You can build and modify your interfaces using the panels and controllers provided by Codux. As the image shows, you can set CSS properties &amp; classes and different element states, for example.</p>
<p><img src="https://catalins.tech/content/images/2023/11/codux-interface.png" alt="Codux Interface" /></p>
<p>And, of course, you also have the code editor at the bottom if you want to make specific changes by writing code.</p>
<blockquote>
<p>Note: Whether you make the changes using the visual editor, the built-in code editor, or your usual IDE, they will always be in sync!</p>
</blockquote>
<p>Codux also supports all the popular styling solutions such as CSS, Sass, CSS/Sass modules, Stylable, and TailwindCSS. The application we're building uses TailwindCSS, for example.</p>
<h3 id="heading-component-playground">Component playground</h3>
<p>Another cool feature of Codux is the playground feature that enables you to share your work (components) with others.</p>
<p>In the playground mode, people can view and edit your components without setting up a local development environment and the other prerequisites.</p>
<p>Let's see it in action. At the beginning of the article, I mentioned that you must upload the project on GitHub. The reason is that the Playground requires your project to be hosted on GitHub.</p>
<p>To share your board (or component), click the "Share" button on the right.</p>
<p><em>Mention: The shared board is public, which means anyone with the link can see it. Be careful.</em></p>
<p><img src="https://catalins.tech/content/images/2023/11/share-project-codux.jpg" alt="Share Project Codux" /></p>
<p>Codux will then ask you to create a link name for the board. Choose a name and click the button "Create Link" (the first time you do it) and "Publish" (afterwards).</p>
<p><em>Mention: Each time you make a change, you need to click the "Update Link" button before sharing the board. Otherwise, your changes won't be applied &amp; visible on the shared board.</em></p>
<p><img src="https://catalins.tech/content/images/2023/11/share-project-codux-customize-link.jpg" alt="Share Project Codux - Customize Sharing Link" /></p>
<p>You can now copy the link and share it with other people. When they access the link, they'll see the online version of Codux (see the picture below).</p>
<p><img src="https://catalins.tech/content/images/2023/11/shared-project-codux.jpg" alt="Shared Project Codux" /></p>
<p>Anyone with the link to the shared board can see it and make changes, including the text, colors, images, and even the code. That makes it an ideal tool for collaborating, where everyone can share &amp; apply their feedback in a simple and direct way.</p>
<p>This way, developers can focus on the work that matters rather than wasting valuable time pushing and pulling changes to/from each other.</p>
<p>It's important to mention, though, that the changes on the shared board don't affect the original board and won't be applied to it. That would be a cool feature, though!</p>
<h2 id="heading-add-the-project-to-codux">Add the project to Codux</h2>
<p>Let's continue by importing the project we created earlier into Codux. Click on the "Open Local Project" option and select the project folder.</p>
<p><img src="https://catalins.tech/content/images/2023/11/import-local-project-codux.png" alt="Import a local project in Codux" /></p>
<p>After that, Codux prompts you to run the configuration scripts, which install the required package to work on the project in this IDE.</p>
<p><img src="https://catalins.tech/content/images/2023/11/run-configuration-scripts-codux.png" alt="Run the configuration scripts for a newly imported project in Codux" /></p>
<p>Once the installation is done, click "Scan for components" so Codux imports all the components.</p>
<p><img src="https://catalins.tech/content/images/2023/11/scan-for-components-codux.png" alt="Scan for the project components" /></p>
<p>Then, you can see all the available components in the sidebar. In our case, we only have one - App - since it's a new project.</p>
<p>You can create new components by clicking the "+ New Component" button, but more on that later.</p>
<p><img src="https://catalins.tech/content/images/2023/11/components-page-codux.png" alt="Components page in Codux" /></p>
<p>As you might've observed, there are "components" and "boards". A "Board" is a concept introduced by Codux, and it represents a fixture for your components so that Codux can automatically render it and allow you to edit it visually.</p>
<p>To create a "board", click on the component and then click the button "+ Create Board". That'll open a menu where you can set the starting point, the board name, and the board path.</p>
<p>You can leave the default options and click "Create".</p>
<p><img src="https://catalins.tech/content/images/2023/11/create-component-board-codux.png" alt="Create a board based on a component in Codux" /></p>
<p>And this is the board view, where you can edit the components visually.</p>
<p><img src="https://catalins.tech/content/images/2023/11/board-view-codux.png" alt="The board view in Codux" /></p>
<h2 id="heading-configure-tailwindcss">Configure TailwindCSS</h2>
<p>For TailwindCSS to work in Codux, you need to perform some customizations in addition to the Tailwind setup process you did at the beginning of the article.</p>
<p>Create the <code>codux.config.js</code> in the root folder of the project, and add the following object:</p>
<pre><code class="lang-json">{
  <span class="hljs-attr">"$schema"</span>: <span class="hljs-string">"https://wixplosives.github.io/codux-config-schema/codux.config.schema.json"</span>,
  <span class="hljs-attr">"boardGlobalSetup"</span>: <span class="hljs-string">"./src/_codux/board-global-setup.ts"</span>
}
</code></pre>
<p>Then, create the <code>board-global-setup.ts</code> in the <code>./src/_codux</code> folder and add the following import:</p>
<pre><code class="lang-ts"><span class="hljs-keyword">import</span> <span class="hljs-string">"../index.css"</span>;
</code></pre>
<p>Done! Now, you can see the TailwindCSS classes in the Codux IDE.</p>
<blockquote>
<p>For more information about this configuration, check this <a target="_blank" href="https://help.codux.com/kb/en/article/using-tailwind-css-with-codux#1.-configure-codux.config.json">link</a>.</p>
</blockquote>
<h2 id="heading-build-the-app">Build the app</h2>
<p>In the following sections, we'll start building the application.</p>
<h3 id="heading-create-the-components-folder">Create the <code>components</code> folder</h3>
<p>Let's start by creating a <code>component</code> folder for all the components. You can either do it from your IDE, terminal, or Codux. This is how you can do it from Codux:</p>
<p><img src="https://catalins.tech/content/images/2023/11/create-new-folder-codux.png" alt="Create components in Codux" /></p>
<p>Click the highlighted icon to see the project files. After that, create the folder as you would create it on your machine. Right-click on the <code>src</code> folder and click <code>New Folder</code>.</p>
<h5 id="heading-creating-components-from-codux">Creating components from Codux</h5>
<p>If you want to create components using the interactive process from Codux, you need to set the components path. You can do that by adding this code in <code>codux.config.json</code>:</p>
<pre><code class="lang-json">{
  <span class="hljs-attr">"$schema"</span>: <span class="hljs-string">"https://wixplosives.github.io/codux-config-schema/codux.config.schema.json"</span>,
  <span class="hljs-attr">"boardGlobalSetup"</span>: <span class="hljs-string">"./src/_codux/board-global-setup.ts"</span>,
  <span class="hljs-attr">"newComponent"</span>: {
    <span class="hljs-attr">"componentsPath"</span>: <span class="hljs-string">"src/components"</span>
  }
}
</code></pre>
<p>Now, you can create components using the visual interface.</p>
<h3 id="heading-layout-component">Layout component</h3>
<p>Create the <code>Layout</code> component in the <code>components</code> folder. We'll use the layout on all the pages.</p>
<p>You can follow the next steps using your usual IDE or Codux.</p>
<p><em>Tip 💡: You're fine either way because the code is automatically in sync between the two. Whether you use Codux or your editor, both will contain the same code without you having to do anything. That's neat!</em></p>
<p>Now open the <code>Layout</code> component and add the following code:</p>
<pre><code class="lang-tsx">type LayoutProps = {
  children: React.ReactNode;
};

export default function Layout({ children }: LayoutProps) {
  return (
    &lt;&gt;
      &lt;main&gt;{children}&lt;/main&gt;
    &lt;/&gt;
  );
}
</code></pre>
<h3 id="heading-refactor-apptsx">Refactor <code>App.tsx</code></h3>
<p>Then go to the <code>App.tsx</code> file and replace the content with the following code:</p>
<pre><code class="lang-tsx">import Layout from "./components/Layout";
import "./App.css";
import { useState } from "react";

function App() {
  const [inputValue, setInputValue] = useState("");
  const [imageURL, setImageURL] = useState("");
  const [loading, setLoading] = useState(false);
  const [error, setError] = useState&lt;null | string&gt;(null);

  const fetchImage = async (prompt: string) =&gt; {
    const response = await fetch("http://localhost:3000/api/genimg", {
      method: "POST",
      headers: {
        "Content-Type": "application/json",
      },
      body: JSON.stringify({ value: prompt }),
    });

    if (response.ok) {
      const data = await response.json();

      if (Array.isArray(data) &amp;&amp; data.length &gt; 0) {
        return data[0];
      }

      throw new Error("Unexpected server response");
    } else {
      throw new Error(response.statusText);
    }
  };

  const onInputChange = (e: React.ChangeEvent&lt;HTMLTextAreaElement&gt;) =&gt; {
    setInputValue(e.target.value);
  };

  const handleSubmit = async (e: React.FormEvent&lt;HTMLFormElement&gt;) =&gt; {
    e.preventDefault();
    setLoading(true);
    setError(null);

    try {
      const url = await fetchImage(inputValue);
      setImageURL(url);
    } catch (err) {
      if (err instanceof Error) {
        setError(err.message);
      } else {
        setError("An unexpected error occurred");
      }
    } finally {
      setLoading(false);
    }
  };

  return (
    &lt;&gt;
      &lt;Layout&gt;
        &lt;section&gt;
          &lt;div&gt;
            &lt;div&gt;
              &lt;h1&gt;PromptPix AI&lt;/h1&gt;
              &lt;p&gt;
                Dive into the world of AI-driven creativity with PromptPix AI,
                where your words become vivid visuals. Simply input your idea,
                and watch as our advanced algorithms craft the image you
                envisioned.
              &lt;/p&gt;
            &lt;/div&gt;
            &lt;form onSubmit={handleSubmit}&gt;
              &lt;div&gt;
                &lt;label htmlFor="prompt"&gt;Image prompt&lt;/label&gt;
                &lt;textarea
                  id="prompt"
                  placeholder="Enter your prompt"
                  value={inputValue}
                  onChange={onInputChange}
                /&gt;
              &lt;/div&gt;
              &lt;button type="submit" disabled={inputValue.length === 0}&gt;
                Generate
              &lt;/button&gt;
            &lt;/form&gt;
          &lt;/div&gt;
          &lt;div&gt;
            {loading &amp;&amp; (
              &lt;div&gt;
                &lt;p&gt;Your image is being generated...&lt;/p&gt;
                &lt;div&gt;
                  &lt;div&gt;
                    &lt;div&gt;
                      &lt;svg
                        xmlns="http://www.w3.org/2000/svg"
                        width="44"
                        height="44"
                        viewBox="0 0 24 24"
                        strokeWidth="2"
                        stroke="currentColor"
                        fill="none"
                        strokeLinecap="round"
                        strokeLinejoin="round"
                      &gt;
                        &lt;path
                          stroke="none"
                          d="M0 0h24v24H0z"
                          fill="none"
                        &gt;&lt;/path&gt;
                        &lt;path d="M12 6l0 -3"&gt;&lt;/path&gt;
                        &lt;path d="M16.25 7.75l2.15 -2.15"&gt;&lt;/path&gt;
                        &lt;path d="M18 12l3 0"&gt;&lt;/path&gt;
                        &lt;path d="M16.25 16.25l2.15 2.15"&gt;&lt;/path&gt;
                        &lt;path d="M12 18l0 3"&gt;&lt;/path&gt;
                        &lt;path d="M7.75 16.25l-2.15 2.15"&gt;&lt;/path&gt;
                        &lt;path d="M6 12l-3 0"&gt;&lt;/path&gt;
                        &lt;path d="M7.75 7.75l-2.15 -2.15"&gt;&lt;/path&gt;
                      &lt;/svg&gt;
                    &lt;/div&gt;
                  &lt;/div&gt;
                &lt;/div&gt;
              &lt;/div&gt;
            )}

            {imageURL &amp;&amp; !loading &amp;&amp; (
              &lt;div&gt;
                &lt;p&gt;Find your generated image below&lt;/p&gt;
                &lt;img
                  src={imageURL}
                  width={600}
                  height={600}
                  alt="Generated image"
                /&gt;
              &lt;/div&gt;
            )}

            {!imageURL &amp;&amp; !loading &amp;&amp; (
              &lt;div&gt;
                &lt;p&gt;Your image will appear below&lt;/p&gt;
                &lt;div&gt;
                  &lt;div&gt;
                    &lt;div&gt;
                      &lt;svg
                        xmlns="http://www.w3.org/2000/svg"
                        width="44"
                        height="44"
                        viewBox="0 0 24 24"
                        strokeWidth="2"
                        stroke="currentColor"
                        fill="none"
                        strokeLinecap="round"
                        strokeLinejoin="round"
                      &gt;
                        &lt;path
                          stroke="none"
                          d="M0 0h24v24H0z"
                          fill="none"
                        &gt;&lt;/path&gt;
                        &lt;path d="M15 8h.01"&gt;&lt;/path&gt;
                        &lt;path d="M11.5 21h-5.5a3 3 0 0 1 -3 -3v-12a3 3 0 0 1 3 -3h12a3 3 0 0 1 3 3v5.5"&gt;&lt;/path&gt;
                        &lt;path d="M18 18m-3 0a3 3 0 1 0 6 0a3 3 0 1 0 -6 0"&gt;&lt;/path&gt;
                        &lt;path d="M20.2 20.2l1.8 1.8"&gt;&lt;/path&gt;
                        &lt;path d="M3 16l5 -5c.928 -.893 2.072 -.893 3 0l2 2"&gt;&lt;/path&gt;
                      &lt;/svg&gt;
                    &lt;/div&gt;
                  &lt;/div&gt;
                &lt;/div&gt;
              &lt;/div&gt;
            )}

            {error &amp;&amp; &lt;div&gt;{error}&lt;/div&gt;}
          &lt;/div&gt;
        &lt;/section&gt;
      &lt;/Layout&gt;
    &lt;/&gt;
  );
}

export default App;
</code></pre>
<p>This component contains the barebone application without any style applied.</p>
<p><img src="https://catalins.tech/content/images/2023/11/barebone-app-codux.png" alt="The app preview in Codux" /></p>
<p><em>Note: Everything is in the</em> <code>App</code> file for illustrative purposes. It's easier to showcase the tool this way. You'll see the final application on GitHub.</p>
<h3 id="heading-style-the-app-with-codux">Style the app with Codux</h3>
<p>Let's start by styling the <code>Layout</code> component first. Double click <code>App</code> in the <code>Elements</code> tab (left-hand side column).</p>
<p>That opens a new tree, where you should see the <code>Layout</code> component. Double click on <code>Layout</code>, and then select <code>main</code>.</p>
<p>The <code>Elements</code> tab shows you all the HTML elements from your code.</p>
<p><img src="https://catalins.tech/content/images/2023/11/main-div.png" alt="Main div" /></p>
<p>To add Tailwind classes to HTML elements, click the "Properties" icon from the right-hand side. Then, search for the "className" property.</p>
<p>Once there, add the following Tailwind classes:</p>
<pre><code class="lang-plaintext">flex min-h-screen flex-col justify-center items-center
</code></pre>
<p>These classes set up a flex container with a minimum height equal to the viewport height, arrange its children in a column, and center them vertically and horizontally within the container.</p>
<p>You should see the changes reflected immediately, both visually and in the code.</p>
<p><img src="https://catalins.tech/content/images/2023/11/classes-applied.png" alt="Applying Tailwind classes in Codux" /></p>
<p>Pretty cool, right?</p>
<p>Now, let's switch to your favorite IDE to see how easy it is to use them together. Open the <code>index.css</code> file and add this block:</p>
<pre><code class="lang-css"><span class="hljs-selector-tag">body</span> {
  @apply bg-gray-50;
}
</code></pre>
<h3 id="heading-app-component">App component</h3>
<p>Continue by adding the following classes to the <code>section</code> element from the <code>App</code> component:</p>
<pre><code class="lang-plaintext">container flex flex-col gap-6 py-8 md:max-w-[64rem] md:py-12 lg:py-24
</code></pre>
<p>These classes modify the section to be a flexible container with column direction, vertical gap between child elements of 6 units, vertical padding of 8 units (increased to 12 units on medium screens and 24 units on large screens), and a maximum width of 64rem on medium and larger screens.</p>
<p><img src="https://catalins.tech/content/images/2023/11/section-classes.png" alt="Applying Tailwind classes in Codux" /></p>
<p>Similarly, apply the following classes to the first <code>div</code> element:</p>
<pre><code class="lang-plaintext">bg-white shadow-md rounded border border-slate-200 p-14 text-center
</code></pre>
<p>These TailwindCSS utility classes apply a white background, a medium shadow, rounded corners, a slate-colored border, padding on all sides of 14 units, and center-aligned text.</p>
<p><img src="https://catalins.tech/content/images/2023/11/div-classes.png" alt="Applying Tailwind classes in Codux" /></p>
<p>This is how the application looks up to this point.</p>
<p><img src="https://catalins.tech/content/images/2023/11/app-progress.png" alt="A screenshot of the Vite + React + TypeScript app built with Codux" /></p>
<p>The next steps are as follows:</p>
<ul>
<li><p>stylize the heading + description</p>
</li>
<li><p>stylize the form</p>
</li>
<li><p>stylize the part where the image will appear</p>
</li>
<li><p>create the API</p>
</li>
</ul>
<p>Let's style the heading and description through your IDE (VS Code, in my case) to see the auto-sync in action.</p>
<p>Replace the 2nd <code>div</code> element with the following code:</p>
<pre><code class="lang-jsx">&lt;div className=<span class="hljs-string">"mx-auto flex w-full flex-col md:max-w-[58rem]"</span>&gt;
   <span class="xml"><span class="hljs-tag">&lt;<span class="hljs-name">h1</span> <span class="hljs-attr">className</span>=<span class="hljs-string">"font-heading text-2xl mb-4 sm:text-4xl text-center"</span>&gt;</span>
      PromptPix AI
   <span class="hljs-tag">&lt;/<span class="hljs-name">h1</span>&gt;</span></span>
   <span class="xml"><span class="hljs-tag">&lt;<span class="hljs-name">p</span> <span class="hljs-attr">className</span>=<span class="hljs-string">"text-sm sm:text-base text-center mb-4"</span>&gt;</span>
      Dive into the world of AI-driven creativity with PromptPix AI,
      where your words become vivid visuals. Simply input your idea,
      and watch as our advanced algorithms craft the image you
      envisioned.
   <span class="hljs-tag">&lt;/<span class="hljs-name">p</span>&gt;</span></span>
&lt;/div&gt;
</code></pre>
<p>The screenshot below illustrates how your code should look:</p>
<p><img src="https://catalins.tech/content/images/2023/11/code-editor-screenshot.png" alt="Cursor.sh screenshot of the code built with Codux" /></p>
<p>If you navigate back to Codux, you will see the changes applied in the visual area and the code editor from the bottom of the page.</p>
<p>Similarly, all the changes made in Codux are available in your IDE.</p>
<p><img src="https://catalins.tech/content/images/2023/11/codux-screenshot.png" alt="Codux screenshot" /></p>
<p>As an exercise, add the following classes to these elements:</p>
<ul>
<li><p>the <code>form</code> element - <code>space-y-6</code></p>
</li>
<li><p>the <code>div</code> element inside the form - <code>flex flex-col items-center gap-4</code></p>
</li>
<li><p>the <code>label</code> element - <code>text-sm sm:text-base</code></p>
</li>
<li><p>the <code>textarea</code> element - <code>border border-slate-200 rounded p-2 w-3/4 h-32 resize-none</code></p>
</li>
<li><p>the <code>button</code> element:</p>
</li>
</ul>
<pre><code class="lang-plaintext">`${
inputValue.length === 0
? "bg-white text-gray-800 font-semibold py-2 px-4 border border-slate-400 rounded shadow opacity-50 hover:opacity-50 cursor-not-allowed"
: "bg-white hover:bg-slate-100 text-gray-800 font-semibold py-2 px-4 border border-slate-400 rounded shadow"
}`
</code></pre>
<p>This is how the application looks like with all the above classes applied:</p>
<p><img src="https://catalins.tech/content/images/2023/11/codux-app-screenshot-progress.png" alt="Screenshot of Codux running React, TypeScript and TailwindCSS" /></p>
<p>Looks pretty good already, right?</p>
<p>The last step involves styling the part where the generated image will appear. We'll make the initial <code>div</code> element (that's displayed before entering any prompt) a flex container with its children arranged in a column, centered horizontally, with a gap of 24px between each child and a top margin of 48px - <code>flex flex-col items-center gap-6 mt-12</code>.</p>
<p>You can add them as usual using the "className" field from Codux.</p>
<p><img src="https://catalins.tech/content/images/2023/11/codux-classes-img.png" alt="Codux TailwindCSS classes" /></p>
<p>Apply the same Tailwind classes to the other 2 <code>div</code> elements that display the loading state and the generated image.</p>
<p>Lastly, stylize the <code>error</code>:</p>
<pre><code class="lang-plaintext">{error &amp;&amp; (
&lt;div className="text-center w-1/2 mx-auto bg-red-500 mt-2 rounded border border-red-800"&gt;
   {error}
&lt;/div&gt;
)}
</code></pre>
<p>Now you're done with the user interface!</p>
<h3 id="heading-codux-offers-much-more">Codux offers much more</h3>
<p>In building this application, you mostly applied classes and visualized the results in real-time. However, Codux offers much more.</p>
<p>With Codux, you can test your application on multiple viewports and make the changes live for each viewport.</p>
<p><img src="https://catalins.tech/content/images/2023/11/codux-responsive.png" alt="Codux responsiveness feature" /></p>
<p>Besides that, we added the classes manually for each element. But you can also use the "Computed Styles" tab to stylize the elements. Instead of writing code manually, you can style elements interactively.</p>
<p><img src="https://catalins.tech/content/images/2023/11/codux-computed-styles.png" alt="Codux computed styles" /></p>
<p>A favorite feature of mine is the ability to open the code for a specific element. You can select the particular element, right-click on it, and open it in the code editor/IDE.</p>
<p>The image illustrates how Codux highlights the relevant code for the selected element. Neat, right?</p>
<p><img src="https://catalins.tech/content/images/2023/11/open-code.png" alt="Open code from Codux" /></p>
<p>As you can see, there are lots of cool features in Codux. I encourage you to <a target="_blank" href="https://codux.hopp.to/catalin">download it</a> and explore it. It's free!</p>
<p>Some valuable resources to help you:</p>
<ul>
<li><p><a target="_blank" href="https://youtu.be/e7lcUQyIxKM?si=vvT66TjqsclE8jYK">Build React Apps with Codux Visual IDE for Faster UI Workflow</a></p>
</li>
<li><p><a target="_blank" href="https://youtu.be/fly6qAcBxi8">Learn How to Build a Standout Portfolio Website Using Codux</a></p>
</li>
<li><p><a target="_blank" href="https://youtu.be/_6k9Bqr0I0A">Craft a Real-Time Weather App From the Ground Up With Codux</a></p>
</li>
<li><p><a target="_blank" href="https://youtu.be/35oplanvybI">Learn All About Visual Component Styling, Including Class Creation and Shaping State, Variables and Computed Styles</a></p>
</li>
</ul>
<h2 id="heading-the-backend-code-for-generating-the-image">The Backend Code for Generating the Image</h2>
<p>You are probably using a different programming language &amp; framework than me. Instead of wasting your time taking you through a painful process of building the backend in a technology you're not interested in, I'll share the code for the API route straightaway.</p>
<pre><code class="lang-ts"><span class="hljs-keyword">import</span> express, { Request, Response } <span class="hljs-keyword">from</span> <span class="hljs-string">"express"</span>;
<span class="hljs-keyword">import</span> Replicate <span class="hljs-keyword">from</span> <span class="hljs-string">"replicate"</span>;
<span class="hljs-keyword">import</span> cors <span class="hljs-keyword">from</span> <span class="hljs-string">"cors"</span>;

<span class="hljs-keyword">const</span> app = express();
<span class="hljs-keyword">const</span> port = <span class="hljs-number">3030</span>;

app.use(express.json());
app.use(cors());

app.options(<span class="hljs-string">"/api/genimg"</span>, <span class="hljs-function">(<span class="hljs-params">req: Request, res: Response</span>) =&gt;</span> {
  <span class="hljs-comment">// Pre-flight request. Reply successfully:</span>
  res.status(<span class="hljs-number">200</span>).end();
});

app.post(<span class="hljs-string">"/api/genimg"</span>, <span class="hljs-keyword">async</span> (req: Request, res: Response) =&gt; {
  <span class="hljs-keyword">const</span> { value } = req.body;

  <span class="hljs-keyword">try</span> {
    <span class="hljs-keyword">const</span> replicate = <span class="hljs-keyword">new</span> Replicate({
      auth: process.env.REPLICATE_API_TOKEN || <span class="hljs-string">""</span>,
    });

    <span class="hljs-keyword">const</span> result = <span class="hljs-keyword">await</span> replicate.run(
      <span class="hljs-string">"stability-ai/stable-diffusion:a00d0b7dcbb9c3fbb34ba87d2d5b46c56969c84a628bf778a7fdaec30b1b99c5"</span>,
      {
        input: {
          prompt: value,
          image_dimensions: <span class="hljs-string">"1024x1024"</span>,
          num_inference_steps: <span class="hljs-number">50</span>,
          num_outputs: <span class="hljs-number">1</span>,
          guideance_scale: <span class="hljs-number">7.5</span>,
          prompt_strength: <span class="hljs-number">0.8</span>,
          scheduler: <span class="hljs-string">"KarrasDPM"</span>,
        },
      }
    );

    res.status(<span class="hljs-number">200</span>).json(result);
  } <span class="hljs-keyword">catch</span> (error) {
    <span class="hljs-built_in">console</span>.error(<span class="hljs-string">"Failed to generate image. Error:"</span>, error);
    res.status(<span class="hljs-number">500</span>).json({ message: <span class="hljs-string">"Failed to generate image"</span> });
  }
});

app.all(<span class="hljs-string">"/api/genimg"</span>, <span class="hljs-function">(<span class="hljs-params">req: Request, res: Response</span>) =&gt;</span> {
  res.status(<span class="hljs-number">405</span>).json({ message: <span class="hljs-string">"Method Not Allowed"</span> });
});

app.listen(port, <span class="hljs-function">() =&gt;</span> {
  <span class="hljs-built_in">console</span>.log(<span class="hljs-string">`Server running at http://localhost:<span class="hljs-subst">${port}</span>`</span>);
});
</code></pre>
<p>This TypeScript code sets up an Express server that listens on port 3030 and has CORS enabled. It defines three routes, all for the path "/api/genimg". The OPTIONS route is for handling pre-flight CORS requests. The POST route accepts a JSON body with a "value" property, uses it as a prompt to generate an image using the Replicate API, and returns the result. If there's an error during this process, it logs it and returns a 500 status code with a failure message. The ALL route is a catch-all that returns a 405 status code, indicating that the method used is not allowed. The server listens on the specified port and logs a message to the console when it's running.</p>
<p>This way, you can adapt the code to your programming language &amp; framework of your choice.</p>
<p><em>Note: You can check the whole application code (both server and client) by accessing this</em> <a target="_blank" href="https://github.com/catalinpit/aimages"><em>GitHub link</em></a><em>.</em></p>
<h2 id="heading-an-ending-note">An ending note</h2>
<p>Building applications comes with challenges that can slow down the development process and make collaboration difficult. One of the main challenges is the constant need to switch between different tools. That takes up considerable time and can break your concentration and flow. Moreover, collaborating with others is cumbersome, often requiring several steps before others can test your work.</p>
<p>This is where Codux steps in to make the whole process smoother and more efficient. Codux enables you to visualize changes as you make them without constantly switching between multiple tools. Moreover, it offers a visual user interface that makes it easier to build applications by allowing you to create things with a couple of clicks. But perhaps most importantly, it allows for real-time collaboration, enabling people to work together seamlessly.</p>
<p>Before closing, I want to mention again that Codux is not here to replace your IDE and other tools you might use. Think of Codux as another tool in your developer toolbox.</p>
<p><em>Disclaimer: This article is sponsored by Wix.</em></p>
<p><em>The article was originally published on my blog -</em> <a target="_blank" href="http://catalins.tech"><em>catalins.tech</em></a></p>
]]></content:encoded></item><item><title><![CDATA[Rethink Full-Stack Development: Is a Custom Backend the Best Choice?]]></title><description><![CDATA[This article covers the conventional way of building full-stack applications and why manually building your backend is not always the best choice. You'll see an alternative solution for your backend needs that can be used standalone or coupled with y...]]></description><link>https://codelounge.dev/rethink-full-stack-development-is-a-custom-backend-the-best-choice</link><guid isPermaLink="true">https://codelounge.dev/rethink-full-stack-development-is-a-custom-backend-the-best-choice</guid><category><![CDATA[backend]]></category><category><![CDATA[APIs]]></category><category><![CDATA[Web Development]]></category><category><![CDATA[software development]]></category><dc:creator><![CDATA[Catalin Pit]]></dc:creator><pubDate>Thu, 22 Jun 2023 12:58:09 GMT</pubDate><enclosure url="https://cdn.hashnode.com/res/hashnode/image/upload/v1687438668506/36823e4e-e7b0-4dae-bd95-f796d75e588c.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>This article covers the conventional way of building full-stack applications and why manually building your backend is not always the best choice. You'll see an alternative solution for your backend needs that can be used standalone or coupled with your custom-built backend.</p>
<h2 id="heading-the-issues-with-the-traditional-backend">The issues with the traditional backend</h2>
<p>The conventional approach to developing full-stack applications involves the tedious and time-consuming process of building the entire application from scratch.</p>
<p>The backend development requires setting and configuring servers, implementing the business logic, and managing databases. Building and maintaining a complex backend from scratch would take substantial resources. So why reinvent the wheel when you can use an existing solution that you can tailor to your needs with code? But more on that later.</p>
<p>It's important to mention that a custom-built backend might be the most appropriate solution in specific scenarios. However, in most cases, an existing solution that you can tailor to your needs through code is more than sufficient. It allows you to speed up the development process and move faster by automating the most tedious work. It also frees up resources so you can focus on business-critical tasks. Besides that, you do not need to choose one or the other. You can have the best of both worlds, as you will see later.</p>
<p>The main pain points are as follows:</p>
<ul>
<li><p>complex and lengthy development process</p>
</li>
<li><p>a substantial amount of resources required</p>
</li>
<li><p>slow time-to-market</p>
</li>
<li><p>maintenance required</p>
</li>
<li><p>scalability and security are difficult</p>
</li>
</ul>
<h2 id="heading-headless-api-solutions">Headless API solutions</h2>
<p>The alternative to custom-built backend applications are the Headless API solutions. A Headless API is an architectural design where the user interface (frontend) is decoupled from the business logic and data storage (backend). The backend exposes the data through an API. The frontend then uses the API to communicate with the backend.</p>
<p>There are multiple advantages to this approach:</p>
<ol>
<li><p>The obvious one is the <strong>faster development process</strong>, since you only need to develop and focus on one part of the application - the frontend. The faster development process also enables you to reduce the time required to enter the market, which is essential in such a competitive landscape.</p>
</li>
<li><p>Since you are using an existing solution for your backend, you <strong>save valuable resources</strong> (finances and time) that you can use on other tasks that are more critical to the business.</p>
</li>
<li><p>Another advantage is that you have <strong>complete freedom when choosing</strong> which <strong>frontend technologies</strong> to use since the application parts are decoupled.</p>
</li>
<li><p>The Headless APIs are developed and maintained by teams of developers who focus exclusively on those APIs, which means these solutions might provide <strong>better security and scalability</strong> than a custom-built solution.</p>
</li>
</ol>
<p>But now you might ask: "Where do I find these APIs?".</p>
<p>That's where Wix Headless comes into the picture. Wix recently released their Headless APIs, enabling developers to implement Wix's robust business solutions using composable APIs and SDK. You can use them with any tech stack across different platforms and devices.</p>
<p>Some of the current available Headless APIs are as follows:</p>
<ul>
<li><p>bookings - The "bookings" API enables you to integrate booking features into your app. It provides features like scheduling and managing appointments, syncing staff calendars, setting up automated reminders, and more.</p>
</li>
<li><p>eCommerce - This API allows you to manage orders, inventory, shipping and finances from one central place. It provides secure payments, optimized checkouts and automated sales taxes.</p>
</li>
<li><p>CMS - The CMS solution offers an API for creating and managing content.</p>
</li>
<li><p>events - It allows you to build applications for hosting in-person or online events, sell tickets, manage guests, accept secure payments, and more.</p>
</li>
<li><p>pricing plans - You can use this headless API to create a members-only platform and offer exclusive access.</p>
</li>
</ul>
<p>You can check all APIs <a target="_blank" href="https://drp.li/wix-solutions">here</a>.</p>
<p>It's important to emphasize that you do not need to choose between the Headless APIs and a custom-built backend. Instead, you can have the best of both worlds since the Headless APIs can be integrated with other internal or 3rd party services.</p>
<h2 id="heading-customize-the-apis">Customize the APIs</h2>
<p>I do not believe in one-size-fits-all solutions. At one point, you will want to modify or extend the functionality through code. You can do that by using the <a target="_blank" href="https://dev.wix.com/api/sdk/sdk-setup:-wix-headless/get-started">Wix Headless SDK</a>.</p>
<p>You can use the SDK by installing the required packages:</p>
<ul>
<li><p><code>@wix/api-client</code> - the package is required to create the API client and to set up the OAuth. When you create the API client, you must provide the modules you want to use (e.g. the eCommerce Headless API).</p>
</li>
<li><p><code>@wix/{api-name}</code> - the <code>api-name</code> should be replaced with the name of the Headless API you need (e.g. "@wix/ecom", "@wix/pricing-plans", "@wix/bookings" and so on). These packages return the modules you pass to the API client configuration and the ones that allow you to interact with the chosen Headless API.</p>
</li>
</ul>
<p>That's all you need to interact with the Headless APIs.</p>
<h2 id="heading-headless-api-examples">Headless API Examples</h2>
<p>In this section, you will see various demos and their code. They are basic, and their sole purpose is to illustrate the basic usage of the Headless APIs.</p>
<h3 id="heading-headless-cms">Headless CMS</h3>
<p>One of the available Headless APIs is the CMS API which provides a user-friendly dashboard for creating and managing content. Let's say we have a landing page for the following APIs:</p>
<ul>
<li><p>bookings</p>
</li>
<li><p>eCommerce</p>
</li>
<li><p>events &amp; tickets</p>
</li>
<li><p>subscriptions</p>
</li>
</ul>
<p>The app makes a request to the CMS backend to fetch information such as the title, slug, and description for each Headless API (<em>see them at the bottom of the page</em>). This is what the landing page looks like:</p>
<p><img src="https://hackmd.io/_uploads/S1HwRGtS3.png" alt="Wix Headless landing page" /></p>
<p>And here's the code that fetches the data:</p>
<pre><code class="lang-javascript"><span class="hljs-keyword">import</span> Link <span class="hljs-keyword">from</span> <span class="hljs-string">'next/link'</span>
<span class="hljs-keyword">import</span> Cookies <span class="hljs-keyword">from</span> <span class="hljs-string">'js-cookie'</span>;
<span class="hljs-keyword">import</span> { useEffect, useState } <span class="hljs-keyword">from</span> <span class="hljs-string">'react'</span>;

<span class="hljs-keyword">import</span> { createClient, OAuthStrategy } <span class="hljs-keyword">from</span> <span class="hljs-string">'@wix/api-client'</span>;
<span class="hljs-keyword">import</span> { items } <span class="hljs-keyword">from</span> <span class="hljs-string">'@wix/data'</span>;

<span class="hljs-keyword">const</span> myWixClient = createClient({
  <span class="hljs-attr">modules</span>: { items },
  <span class="hljs-attr">auth</span>: OAuthStrategy({
    <span class="hljs-attr">clientId</span>: <span class="hljs-string">`&lt;your-client-id&gt;`</span>,
    <span class="hljs-attr">tokens</span>: <span class="hljs-built_in">JSON</span>.parse(Cookies.get(<span class="hljs-string">'session'</span>) || <span class="hljs-literal">null</span>)
  })
});

<span class="hljs-keyword">export</span> <span class="hljs-keyword">default</span> <span class="hljs-function"><span class="hljs-keyword">function</span> <span class="hljs-title">Examples</span>(<span class="hljs-params"></span>) </span>{
  <span class="hljs-keyword">const</span> [examples, setExamples] = useState([]);

  <span class="hljs-keyword">async</span> <span class="hljs-function"><span class="hljs-keyword">function</span> <span class="hljs-title">fetchExamples</span>(<span class="hljs-params"></span>) </span>{
    <span class="hljs-keyword">const</span> examples = <span class="hljs-keyword">await</span> myWixClient.items.queryDataItems({ <span class="hljs-attr">dataCollectionId</span>: <span class="hljs-string">'examples'</span> }).ascending(<span class="hljs-string">'orderId'</span>).find();
    setExamples(examples.items);
  }

  useEffect(<span class="hljs-function">() =&gt;</span> { fetchExamples(); }, []);

  <span class="hljs-keyword">return</span> (
    <span class="xml"><span class="hljs-tag">&lt;<span class="hljs-name">footer</span>&gt;</span>
      {examples.map((example) =&gt; (
        <span class="hljs-tag">&lt;<span class="hljs-name">Link</span> <span class="hljs-attr">href</span>=<span class="hljs-string">{example.data.slug}</span> <span class="hljs-attr">key</span>=<span class="hljs-string">{example._id}</span>&gt;</span>
          <span class="hljs-tag">&lt;<span class="hljs-name">section</span>&gt;</span>
            <span class="hljs-tag">&lt;<span class="hljs-name">h2</span>&gt;</span>{example.data.title} <span class="hljs-tag">&lt;<span class="hljs-name">span</span>&gt;</span>-<span class="hljs-symbol">&amp;gt;</span><span class="hljs-tag">&lt;/<span class="hljs-name">span</span>&gt;</span><span class="hljs-tag">&lt;/<span class="hljs-name">h2</span>&gt;</span>
            <span class="hljs-tag">&lt;<span class="hljs-name">p</span>&gt;</span>{example.data.description}<span class="hljs-tag">&lt;/<span class="hljs-name">p</span>&gt;</span>
          <span class="hljs-tag">&lt;/<span class="hljs-name">section</span>&gt;</span>
        <span class="hljs-tag">&lt;/<span class="hljs-name">Link</span>&gt;</span>
      ))}
    <span class="hljs-tag">&lt;/<span class="hljs-name">footer</span>&gt;</span></span>
  )
}
</code></pre>
<p>The first step involves adding all the required imports at the top of the file. The next step is to create and configure the Wix API client. It requires you to specify the modules you want to use (<code>items</code> from the <code>@wix/data</code> package in this case) and the <code>clientId</code> for the <code>OAuth</code> strategy.</p>
<p>After that, you use the Wix client to fetch and display the data on the page. As the figure illustrates, it's a simple application. However, you can check a more complex application using the Headless CMS <a target="_blank" href="https://github.com/wix/wix-cms-nextjs-template">here</a>.</p>
<h3 id="heading-bookings-api">Bookings API</h3>
<p>Another API available is the bookings API, which enables you to integrate booking features into your applications. For example, you can set up flexible booking features based on location and availability, schedule or manage appointments, sync staff calendars, set up automated reminders and more.</p>
<p>The figure below illustrates an example using the bookings API, where users can select a service and a time slot.</p>
<p><img src="https://hackmd.io/_uploads/rywX11cBn.png" alt="An example of the Wix booking headless API" /></p>
<p>After you choose a service and a time slot, you are redirected to a new page where you need to enter your details for the purchase. Once all the details are entered, you can add the purchase to the cart or book it straight away.</p>
<p><img src="https://hackmd.io/_uploads/r1c4z15r3.png" alt="An example of the Wix booking headless API purchase page" /></p>
<p>In this case, I clicked the "Add to Cart" button, which took me to the cart page. You can enter a promo code or add a note on this page. Once you are done, you can click the "Checkout" button to finalize the purchase.</p>
<p><img src="https://hackmd.io/_uploads/SkH3Gk5rh.png" alt="An example of the Wix booking headless API cart page" /></p>
<p>The code is similar to the previous example in the sense that you need to create the Wix client and pass the appropriate modules. After that, it's the usual React code.</p>
<pre><code class="lang-javascript"><span class="hljs-keyword">import</span> Cookies <span class="hljs-keyword">from</span> <span class="hljs-string">'js-cookie'</span>;
<span class="hljs-keyword">import</span> { useEffect, useState } <span class="hljs-keyword">from</span> <span class="hljs-string">'react'</span>;

<span class="hljs-keyword">import</span> { createClient, OAuthStrategy } <span class="hljs-keyword">from</span> <span class="hljs-string">'@wix/api-client'</span>;
<span class="hljs-keyword">import</span> { availabilityCalendar, services } <span class="hljs-keyword">from</span> <span class="hljs-string">'@wix/bookings'</span>;
<span class="hljs-keyword">import</span> { redirects } <span class="hljs-keyword">from</span> <span class="hljs-string">'@wix/redirects'</span>;

<span class="hljs-keyword">const</span> myWixClient = createClient({
  <span class="hljs-attr">modules</span>: { services, availabilityCalendar, redirects },
  <span class="hljs-attr">auth</span>: OAuthStrategy({
    <span class="hljs-attr">clientId</span>: <span class="hljs-string">`&lt;your-client-id&gt;`</span>,
    <span class="hljs-attr">tokens</span>: <span class="hljs-built_in">JSON</span>.parse(Cookies.get(<span class="hljs-string">'session'</span>) || <span class="hljs-literal">null</span>)
  })
});

<span class="hljs-keyword">export</span> <span class="hljs-keyword">default</span> <span class="hljs-function"><span class="hljs-keyword">function</span> <span class="hljs-title">Booking</span>(<span class="hljs-params"></span>) </span>{
  <span class="hljs-keyword">const</span> [serviceList, setServiceList] = useState([]);
  <span class="hljs-keyword">const</span> [availabilityEntries, setAvailabilityEntries] = useState([]);

  <span class="hljs-keyword">async</span> <span class="hljs-function"><span class="hljs-keyword">function</span> <span class="hljs-title">fetchServices</span>(<span class="hljs-params"></span>) </span>{
    <span class="hljs-keyword">const</span> serviceList = <span class="hljs-keyword">await</span> myWixClient.services.queryServices().find();
    setServiceList(serviceList.items);
  }

  <span class="hljs-keyword">async</span> <span class="hljs-function"><span class="hljs-keyword">function</span> <span class="hljs-title">fetchAvailability</span>(<span class="hljs-params">service</span>) </span>{
    <span class="hljs-keyword">const</span> today = <span class="hljs-keyword">new</span> <span class="hljs-built_in">Date</span>();
    <span class="hljs-keyword">const</span> tomorrow = <span class="hljs-keyword">new</span> <span class="hljs-built_in">Date</span>(today);
    tomorrow.setDate(tomorrow.getDate() + <span class="hljs-number">1</span>);

    <span class="hljs-keyword">const</span> availability = <span class="hljs-keyword">await</span> myWixClient.availabilityCalendar.queryAvailability({
      <span class="hljs-attr">filter</span>: { <span class="hljs-attr">serviceId</span>: [service._id], <span class="hljs-attr">startDate</span>: today.toISOString(), <span class="hljs-attr">endDate</span>: tomorrow.toISOString() }
    }, { <span class="hljs-attr">timezone</span>: <span class="hljs-string">'UTC'</span> });
    setAvailabilityEntries(availability.availabilityEntries);
  }

  <span class="hljs-keyword">async</span> <span class="hljs-function"><span class="hljs-keyword">function</span> <span class="hljs-title">createRedirect</span>(<span class="hljs-params">slotAvailability</span>) </span>{
    <span class="hljs-keyword">const</span> redirect = <span class="hljs-keyword">await</span> myWixClient.redirects.createRedirectSession({
      <span class="hljs-attr">bookingsCheckout</span>: { slotAvailability, <span class="hljs-attr">timezone</span>: <span class="hljs-string">'UTC'</span> },
      <span class="hljs-attr">callbacks</span>: { <span class="hljs-attr">postFlowUrl</span>: <span class="hljs-built_in">window</span>.location.href }
    });
    <span class="hljs-built_in">window</span>.location = redirect.redirectSession.fullUrl;
  }

  useEffect(<span class="hljs-function">() =&gt;</span> { fetchServices(); }, []);

  <span class="hljs-keyword">return</span> (
    <span class="xml"><span class="hljs-tag">&lt;<span class="hljs-name">main</span>&gt;</span>
      <span class="hljs-tag">&lt;<span class="hljs-name">div</span>&gt;</span>
        <span class="hljs-tag">&lt;<span class="hljs-name">h2</span>&gt;</span>Choose a Service:<span class="hljs-tag">&lt;/<span class="hljs-name">h2</span>&gt;</span>
        {serviceList.map((service) =&gt; {
          return <span class="hljs-tag">&lt;<span class="hljs-name">section</span> <span class="hljs-attr">key</span>=<span class="hljs-string">{service._id}</span> <span class="hljs-attr">onClick</span>=<span class="hljs-string">{()</span> =&gt;</span> fetchAvailability(service)}&gt;{service.name}<span class="hljs-tag">&lt;/<span class="hljs-name">section</span>&gt;</span>;
        })}
      <span class="hljs-tag">&lt;/<span class="hljs-name">div</span>&gt;</span>
      <span class="hljs-tag">&lt;<span class="hljs-name">div</span>&gt;</span>
        <span class="hljs-tag">&lt;<span class="hljs-name">h2</span>&gt;</span>Choose a Slot:<span class="hljs-tag">&lt;/<span class="hljs-name">h2</span>&gt;</span>
        {availabilityEntries.map((entry) =&gt; {
          return <span class="hljs-tag">&lt;<span class="hljs-name">section</span> <span class="hljs-attr">key</span>=<span class="hljs-string">{entry.slot.startDate}</span> <span class="hljs-attr">onClick</span>=<span class="hljs-string">{()</span> =&gt;</span> createRedirect(entry)}&gt;{new Date(entry.slot.startDate).toLocaleString()}<span class="hljs-tag">&lt;/<span class="hljs-name">section</span>&gt;</span>;
        })}
      <span class="hljs-tag">&lt;/<span class="hljs-name">div</span>&gt;</span>
    <span class="hljs-tag">&lt;/<span class="hljs-name">main</span>&gt;</span></span>
  )
}
</code></pre>
<p>Even though the example application is quite basic, it demonstrates how valuable and powerful the headless APIs are. They provide many features out of the box without requiring you to do any backend work.</p>
<p>Moreover, it provides a visual interface for managing the backend data. In this example, you can add, edit or remove services using the Wix dashboard. It also enables you to accept payments and manage orders. As a result, one is not required to be a developer to manage the backend.</p>
<p><img src="https://hackmd.io/_uploads/rk_psJqrn.png" alt="Wix dashboard" /></p>
<p>With that being said, you can check more complex applications using the Headless Bookings API here:</p>
<ul>
<li><p><a target="_blank" href="https://github.com/wix/wix-appointments-subscriptions-nextjs-template">Bookings app for a professional coach</a></p>
</li>
<li><p><a target="_blank" href="https://github.com/wix/wix-classes-subscriptions-nextjs-template">Bookings app for a personal trainer</a></p>
</li>
</ul>
<h3 id="heading-more-examples">More examples</h3>
<p>This article presented two example applications to illustrate the usage of the APIs. All the examples shown in this article, and some more, are available in <a target="_blank" href="https://github.com/wix/wix-headless-example">this repository</a>. Moreover, there are a handful of production-ready templates you can use as a starter. Check them out <a target="_blank" href="https://www.wix.com/developers/headless/templates">here</a>. They are more complex, and thus, they show how to build a production-ready application using these APIs.</p>
<h2 id="heading-conclusion">Conclusion</h2>
<p>The Headless APIs are excellent alternatives to building custom backend applications from scratch. However, you do not always have to choose between the two solutions. If you already have a custom-built backend, you can integrate these APIs into your existing backend application without requiring a total overhaul.</p>
<p>One of the most important benefits of using an existing solution is saving valuable resources such as finances and time. These resources can then be spent on more business-critical tasks.</p>
<p>In addition to that, these Headless APIs reduce or even eliminate the complex and lengthy development cycles. As a result, your product can reach the market sooner. The faster the time-to-market, the better.</p>
<p>Lastly, they are built and maintained by teams of experienced developers. They are made with scalability and security in mind. That means you do not have to worry when the business gets bigger and requires more resources &amp; better security because they handle that for you.</p>
<p>In conclusion, whatever approach you take, you can be assured that these APIs will provide many benefits and save valuable resources.</p>
<div class="embed-wrapper"><div class="embed-loading"><div class="loadingRow"></div><div class="loadingRow"></div></div><a class="embed-card" href="https://youtu.be/JDode_bW9bw">https://youtu.be/JDode_bW9bw</a></div>
<p> </p>
<p><em>The article was originally posted on my blog -</em> <a target="_blank" href="https://catalins.tech/headless-api/"><em>Rethink Full-Stack Development: Is a Custom Backend the Best Choice?</em></a></p>
]]></content:encoded></item><item><title><![CDATA[9 Websites To Find Remote Developer Jobs]]></title><description><![CDATA[The way people work has changed dramatically in the last few years. The working world shifted to remote work, with more and more people working remotely nowadays.
That's the case with developers. However, sometimes it can be difficult to find remote ...]]></description><link>https://codelounge.dev/9-websites-to-find-remote-developer-jobs</link><guid isPermaLink="true">https://codelounge.dev/9-websites-to-find-remote-developer-jobs</guid><category><![CDATA[General Advice]]></category><category><![CDATA[100DaysOfCode]]></category><category><![CDATA[General Programming]]></category><dc:creator><![CDATA[CodeLounge]]></dc:creator><pubDate>Wed, 21 Apr 2021 05:42:56 GMT</pubDate><enclosure url="https://cdn.hashnode.com/res/hashnode/image/upload/v1618983751482/GpvzUgxsL.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>The way people work has changed dramatically in the last few years. The working world shifted to remote work, with more and more people working remotely nowadays.</p>
<p>That's the case with developers. However, sometimes it can be difficult to find remote developer jobs. As a result, below you can see 7 websites to find remote developer jobs:</p>
<ul>
<li><a target="_blank" href="https://weworkremotely.com/">We Work Remotely</a></li>
<li><a target="_blank" href="https://stackoverflow.com/jobs/remote-developer-jobs">Stackoverflow Remote Developer Jobs</a></li>
<li><a target="_blank" href="https://github.com/remoteintech/remote-jobs">Remote Jobs</a></li>
<li><a target="_blank" href="https://remoteok.io/remote-dev-jobs">Remote OK</a></li>
<li><a target="_blank" href="https://remote.co/remote-jobs/developer">Remote Developer Jobs</a></li>
<li><a target="_blank" href="https://remoteleads.io/">Remote Leads</a></li>
<li><a target="_blank" href="https://docs.google.com/spreadsheets/d/1TLJSlNxCbwRNxy14Toe1PYwbCTY7h0CNHeer9J0VRzE/htmlview#gid=1279011369">Remotive</a></li>
<li><a target="_blank" href="https://remoteleads.io/">Remote Leaf</a></li>
<li><a target="_blank" href="https://docs.google.com/spreadsheets/d/1Sr0vy3eDn2fcEhxOdkPv0BjsWBR7JntDJqRM6_hyjbE/edit#gid=0">Companies with open remote positions</a></li>
</ul>
<p>Hopefully, the list helps you find a remote developer position. If you find it useful, share it with others!</p>
]]></content:encoded></item><item><title><![CDATA[7 GitHub Repositories To Help You Crush Your Job Interviews]]></title><description><![CDATA["In tech, interviews are harder than the actual jobs". This is a joke, but it can be true in many cases. Thus, in this article, you will see 7 GitHub repositories that will help you ace the interviews.
These repositories include information about:

H...]]></description><link>https://codelounge.dev/7-github-repositories-to-help-you-crush-your-job-interviews</link><guid isPermaLink="true">https://codelounge.dev/7-github-repositories-to-help-you-crush-your-job-interviews</guid><category><![CDATA[General Advice]]></category><category><![CDATA[interview]]></category><category><![CDATA[100DaysOfCode]]></category><category><![CDATA[#codenewbies]]></category><dc:creator><![CDATA[Catalin Pit]]></dc:creator><pubDate>Fri, 16 Apr 2021 12:09:06 GMT</pubDate><enclosure url="https://cdn.hashnode.com/res/hashnode/image/upload/v1618574930986/d9WANWnHr.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>"In tech, interviews are harder than the actual jobs". This is a joke, but it can be true in many cases. Thus, in this article, you will see 7 GitHub repositories that will help you ace the interviews.</p>
<p>These repositories include information about:</p>
<ul>
<li>How the web works (DNS, HTTP, and many more subjects)</li>
<li>Data Structures and Algorithms</li>
<li>How to design large-scale systems (System Design)</li>
<li>Application Security</li>
<li>JavaScript Algorithms</li>
</ul>
<hr />
<h1 id="1-coding-interview-university">1. Coding Interview University</h1>
<p><img src="https://dev-to-uploads.s3.amazonaws.com/i/usns6b0d6stjf03ihhlg.png" alt="Alt Text" />
The Coding Interview repository is one of the most comprehensive resources for interview preparation. The repository started as a study plan of the repository owner, which he used to become a software engineer.</p>
<p>In this repository, you can find information about Data Structures, Algorithms, Dynamic Programming, Object-Oriented Programming, Design Patterns and more.</p>
<p>I recommend you to check the <a target="_blank" href="https://github.com/jwasham/coding-interview-university">repository here</a> and explore it on your own. Be aware that it's comprehensive and you do not have to learn everything or everything at once. Nonetheless, the resource is extremely handy to prepare for interviews.</p>
<hr />
<h1 id="2-tech-interview-handbook">2. Tech Interview Handbook</h1>
<p><img src="https://dev-to-uploads.s3.amazonaws.com/i/vxflp5wuhslele8pkoyo.png" alt="Alt Text" />
Another useful resource is the Tech Interview Handbook. It covers information about technical interviews but not only. It also covers the job application (resume, cover letter), the interview process (behavioural questions, what questions to ask in the interview), and the post-interview (negotiation).</p>
<p>Thus, you learn more than just Data Structures, Algorithms and other technical subjects. The Tech Interview Handbook is a handy resource, and I encourage you to <a target="_blank" href="https://yangshun.github.io/tech-interview-handbook/">check it here</a>.</p>
<hr />
<h1 id="3-the-system-design-primer">3. The System Design Primer</h1>
<p><img src="https://dev-to-uploads.s3.amazonaws.com/i/3kiiw3mrx1pmvp2nnlhd.png" alt="Alt Text" />
For small side projects, we might get away without planning or too much thinking. However, building large-scale systems is a different game. Learning how to design scalable systems will help you become a software engineer.</p>
<p>Thus, the <a target="_blank" href="https://github.com/donnemartin/system-design-primer">System Design Primer repository</a> is a collection of materials and resources from the internet. The owner of the repository put together resources and materials from different sources. Besides, the repository is continuously updated, so keep an eye on it!</p>
<p>The repo contains a study guide, how to approach system design questions, and solutions to the questions. I highly recommend it, and I use it as well to learn more about designing scalable applications.</p>
<hr />
<h1 id="4-interview-resources">4. Interview Resources</h1>
<p><img src="https://dev-to-uploads.s3.amazonaws.com/i/ejrw1e2gykmf67yx367i.png" alt="Alt Text" />
The <a target="_blank" href="https://github.com/Olshansk/interview">Interview</a> repository does not have a description or a guide on how you should use it. It only lists links to other resources, and it groups these links by their topic. For instance, there is the <strong>Algorithms</strong> section that includes:</p>
<ul>
<li>Books</li>
<li>Coding Practice</li>
<li>Guides</li>
<li>Misc</li>
</ul>
<p>I like this repository in particular, because of the number of resources included. Also, I like that they are categorised by type. Besides that, it deserves an extra point for having similar repositories at the end. That is additional resources to prepare for your interviews. Do check out the repository!</p>
<hr />
<h1 id="5-how-to-secure-anything">5. How To Secure Anything</h1>
<p><img src="https://dev-to-uploads.s3.amazonaws.com/i/gae1x8d6bp85k2aby2np.png" alt="Alt Text" />
Security was, is, and will always be an essential topic when building applications. If your applications are not secure, it can result in disastrous consequences.</p>
<p>Therefore, security is not something to take lightly. As a result, here we have the repository <a target="_blank" href="https://github.com/veeral-patel/how-to-secure-anything">How To Secure Anything</a>. The nice thing about this repository is that the information applies to securing anything, not only applications. The repository owner claims to "aim to document a process for securing anything, whether it's a medieval castle, an art museum, or a computer network".</p>
<p>The repository is very well laid-out, and it includes a lot of extra materials to supplement your learning. I cannot recommend it enough!</p>
<hr />
<h1 id="6-how-the-web-works">6. How The Web Works</h1>
<p><img src="https://dev-to-uploads.s3.amazonaws.com/i/feqwwazk8z1x4kbp7qjd.png" alt="Alt Text" />
In the interview for my first developer job, I was asked: <em>what happens when you type a URL in a browser?</em>. Probably, you encountered the same question, or maybe you will in the future.</p>
<p>Thus, you can find the answer to such questions in the repo called <a target="_blank" href="https://github.com/vasanthk/how-web-works">How Web Works</a>. You can find information about how DNS, HTTP protocol and server work or about DOM Tree, Render Tree, page painting and so on.</p>
<p>It is a handy repository to learn the basics of how the web works. Moreover, the repository includes additional links to explore some subjects in-depth.</p>
<hr />
<h1 id="7-javascript-algorithms">7. JavaScript Algorithms</h1>
<p><img src="https://dev-to-uploads.s3.amazonaws.com/i/ew0yt6mh9si6tcb9maw9.png" alt="Alt Text" />
The <a target="_blank" href="https://github.com/trekhleb/javascript-algorithms">JavaScript Algorithms repository</a> is more tailored to JavaScript positions. Although, if you understand the concepts, and know how to implement them in JavaScript, you will most likely know how to implement them in other languages too.</p>
<p>Each Data Structure and Algorithm comes with its separate README, and it also includes links to further material. Thus, if you do not understand a concept, you can always follow the additional material for extra information.</p>
<p>Although I want to mention that some information might be scarce, and you might need additional learning material; nonetheless, the repository is excellent to practice Algorithms and Data Structures.</p>
<hr />
<h1 id="conclusion">Conclusion</h1>
<p>I hope these resources help you ace your next technical interview. The resources from the article are super helpful; especially if you use them together.</p>
<p>The list from the article is not exhaustive, but it should cover anything you might encounter in an interview. As always, I am open to suggestions. Thus, if you know other great resources, feel free to drop them in the comments!</p>
]]></content:encoded></item><item><title><![CDATA[12 Resources To Improve Your CSS Skills And Speed Up CSS Development]]></title><description><![CDATA[If you enjoyed the article, subscribe to our newsletter above to stay up-to-date with all the articles! Additionally, it would help if you would share the article on social media. Thank you!

In this article, you can find a list of resources that wil...]]></description><link>https://codelounge.dev/12-resources-to-improve-your-css-skills-and-speed-up-css-development</link><guid isPermaLink="true">https://codelounge.dev/12-resources-to-improve-your-css-skills-and-speed-up-css-development</guid><category><![CDATA[CSS]]></category><category><![CDATA[100DaysOfCode]]></category><category><![CDATA[General Advice]]></category><dc:creator><![CDATA[CodeLounge]]></dc:creator><pubDate>Fri, 09 Apr 2021 05:15:22 GMT</pubDate><enclosure url="https://cdn.hashnode.com/res/hashnode/image/upload/v1617945316465/wPqMF54MZ.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<blockquote>
<p>If you enjoyed the article, subscribe to our newsletter above to stay up-to-date with all the articles! Additionally, it would help if you would share the article on social media. Thank you!</p>
</blockquote>
<p>In this article, you can find a list of resources that will help you improve your CSS skills and speed up CSS development. More specifically, there are twelve fantastic resources!</p>
<p>Some of them are learning resources from where you can learn the CSS fundamentals, whereas others are generators that help you save time! Without further ado, let's see the resources!</p>
<hr />
<h1 id="1-awesome-css-learninghttpsgithubcommicromataawesome-css-learning">1. <a target="_blank" href="https://github.com/micromata/awesome-css-learning">Awesome CSS Learning</a></h1>
<p>"Awesome CSS Learning" is a GitHub repository that contains links to amazing CSS learning resources. This resource is mainly about the language and its modules.</p>
<p>You can find links to learn concepts such as:</p>
<ul>
<li>Fundamental concepts</li>
<li>CSS units</li>
<li>Selectors</li>
<li>Custom properties (aka CSS variables)</li>
<li>Layout</li>
<li>Animation</li>
<li>Related</li>
</ul>
<p>If you are looking for resources to learn the CSS fundamentals, this repository is excellent!</p>
<hr />
<h1 id="2-css-waves-generatorhttpsgetwavesio">2. <a target="_blank" href="https://getwaves.io/">CSS Waves Generator</a></h1>
<p>This CSS generator allows you to create SVG waves, which you can use in any way you want.</p>
<p>You can choose:</p>
<ul>
<li>the shape of the waves</li>
<li>the direction</li>
<li>the colour</li>
<li>the opacity</li>
<li>the "curviness"</li>
</ul>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1617944640217/ekUVOgrhj.png" alt="getwaves.io-website" /></p>
<p>It's a nice, handy tool that you can use to generate some section separators or art for your website.</p>
<hr />
<h1 id="3-magic-of-csshttpsgithubcomadamschwartzmagic-of-css">3. <a target="_blank" href="https://github.com/adamschwartz/magic-of-css">Magic of CSS</a></h1>
<p>This GitHub repository is the repository behind the <a target="_blank" href="https://adamschwartz.co/magic-of-css/">Magic of CSS</a> website. According to its GitHub description, it's a CSS course, and it's for web developers who want to be "magicians".</p>
<p>The "Magic of CSS" course is split into six chapters:</p>
<ul>
<li>Chapter 1: The Box</li>
<li>Chapter 2: Layout</li>
<li>Chapter 3: Tables</li>
<li>Chapter 4: Color</li>
<li>Chapter 5: Typography</li>
<li>Chapter 6: Transitions</li>
</ul>
<p>Essentially, this course teaches you the fundamentals of CSS. One of the best thing about this course is that it includes links to further material. For instance, if you want to learn more about a concept, you can use the linked resources.</p>
<hr />
<h1 id="4-css-separator-generatorhttpswwebdevresourcescss-separator-generator">4. <a target="_blank" href="https://wweb.dev/resources/css-separator-generator">CSS Separator Generator</a></h1>
<p>Split your website section with style! This CSS generator allows you to generate fancy section separators. </p>
<p>You can customise the separator, and you can see the preview in real-time. Once you decide what separator to use, the website gives you the HTML and CSS.</p>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1617892537462/h27tJpbm8.png" alt="Screenshot 2021-04-08 at 17.34.53.png" /></p>
<p>The above figure illustrates the generator in action. It's a super handy tool that improves the design of your website!</p>
<hr />
<h1 id="5-spin-kithttpsgithubcomtobiasahlinspinkit">5. <a target="_blank" href="https://github.com/tobiasahlin/SpinKit">Spin Kit</a></h1>
<p>SpinKit is a CSS package that allows you to use simple animated loading spinners. It only uses <code>transform</code> and <code>opacity</code> to create smooth, nice looking and easily customisable animations.</p>
<p>To use SpinKit, you have to install it via <code>bower</code> or <code>npm</code>. After that, all you have to do is to use the class you want for your animation. For instance, if you wish to use the "pulse" animation, you need to use the <code>sk-pulse</code> class:</p>
<pre><code><span class="hljs-tag">&lt;<span class="hljs-name">div</span> <span class="hljs-attr">class</span>=<span class="hljs-string">"sk-pulse"</span>&gt;</span>
.... your code
<span class="hljs-tag">&lt;/<span class="hljs-name">div</span>&gt;</span>
</code></pre><p>It's a handy CSS package, and you can see all the animations on the <a target="_blank" href="https://tobiasahlin.com/spinkit/">SpinKit's official website</a>. You can test all animations and see how they look before using them.</p>
<hr />
<h1 id="6-shadow-generatorhttpsshadowsbrummaf">6. <a target="_blank" href="https://shadows.brumm.af/">Shadow Generator</a></h1>
<p>This shadow generator application allows you to create and customise shadows (<code>box-shadow</code>). See a picture with the generator below!</p>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1617944723207/I8_ypi3gz.png" alt="CSS shadow generator" /></p>
<p>You can customise the:</p>
<ul>
<li>layers of shadows</li>
<li>final transparency</li>
<li>final vertical distance</li>
<li>final blur strength</li>
<li>reduce spread</li>
</ul>
<p>It's a great resource because you can see how the shadow looks in real-time. If you want to create beautiful shadows, I recommend you this generator.</p>
<hr />
<h1 id="7-css-hoverhttpsgithubcomianlunnhover">7. <a target="_blank" href="https://github.com/IanLunn/Hover">CSS Hover</a></h1>
<p>The "CSS Hover" package is a collection of hover effects you use on links, buttons, logos, SVGs and more. You can use and modify them as you see fit!</p>
<p>You can use this package in three ways:</p>
<ul>
<li>install it via npm</li>
<li>install it via bower</li>
<li>download the CSS file directly</li>
</ul>
<p>If you do not want to install it or add all the animations to your project, simply open the CSS file and copy only the effect you want. You can check each hover effect on the <a target="_blank" href="http://ianlunn.github.io/Hover/">Hover's official website</a>.</p>
<hr />
<h1 id="8-css-grid-generatorhttpscssgrid-generatornetlifyapp">8. <a target="_blank" href="https://cssgrid-generator.netlify.app/">CSS Grid Generator</a></h1>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1617944792140/K7DFd9TSh.png" alt="CSS Grid generator" /></p>
<p>The CSS grid generator allows you to create a custom CSS grid. You can specify the number of <strong>columns</strong> and <strong>rows</strong>. Additionally, you can set the <strong>column</strong> and <strong>row gaps</strong> in pixels.</p>
<p>There is not much to say about the generator other than it's fantastic! See the application in the picture above.</p>
<hr />
<h1 id="9-awesome-csshttpsgithubcomawesome-css-groupawesome-css">9. <a target="_blank" href="https://github.com/awesome-css-group/awesome-css">Awesome CSS</a></h1>
<p>The "Awesome CSS" repository is a curated list of CSS resources. According to its description, it's a list of "awesome frameworks, style guides, and other cool nuggets for writing amazing CSS".</p>
<p>It's important to note that it does not include material to learn CSS. This resource is recommended for people who already know CSS, or at least the basics.</p>
<p>Some of the information you can find in this repository include:</p>
<ul>
<li>Parsers</li>
<li>Preprocessors</li>
<li>Frameworks</li>
<li>Toolkits</li>
<li>CSS Structure</li>
</ul>
<p>... and more. It's worth checking it out!</p>
<hr />
<h1 id="10-css-clip-path-makerhttpsbennettfeelycomclippy">10. <a target="_blank" href="https://bennettfeely.com/clippy/">CSS Clip Path Maker</a></h1>
<blockquote>
<p>"The clip-path property allows you to make complex shapes in CSS by clipping an element to a basic shape (circle, ellipse, polygon, or inset) or an SVG source.</p>
</blockquote>
<p>Thus, the CSS clip-path maker allows you to generate clip-path values to spice up your website! You can see the generator in action below.</p>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1617893062854/E8Od23uuW.png" alt="Screenshot 2021-04-08 at 17.43.55.png" /></p>
<hr />
<h1 id="11-fancy-border-generatorhttps9elementsgithubiofancy-border-radius">11. <a target="_blank" href="https://9elements.github.io/fancy-border-radius/">Fancy Border Generator</a></h1>
<p>Say goodbye to boring borders. From now on, you can use this border generator to create some beautiful borders!</p>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1617893293937/baF5OJkja.png" alt="Screenshot 2021-04-08 at 17.47.26.png" /></p>
<p>You might ask - how is that possible? It's possible because by specifying eight values for the border-radius property, you can build organic-looking shapes. The generator is awesome!</p>
<hr />
<h1 id="12-gradients-generatorhttpslarsenworkcomeasing-gradients">12. <a target="_blank" href="https://larsenwork.com/easing-gradients/">Gradients Generator</a></h1>
<p>The usual linear gradients usually have hard edges where they start and/or end. However, you can make them look smoother by easing them.</p>
<p>The figure below illustrates the difference between a linear gradient and easing. You can see that easing a linear gradient makes it look much better!</p>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1617893674043/3Cgkssks9.png" alt="Screenshot 2021-04-08 at 17.54.21.png" /></p>
<p>It's important to note that it's not yet a CSS feature. You can a PostCSS/Figma plugin for it or the editor from the website.</p>
<hr />
<h1 id="conclusion">Conclusion</h1>
<p>I hope you find these CSS resources. If you do, share the article on social media so other people can benefit!</p>
<p>Also, if you have other suggestions, leave them in the comments below!</p>
]]></content:encoded></item><item><title><![CDATA[5 Best Resources To Learn JavaScript For Free]]></title><description><![CDATA[There are countless resources to learn JavaScript, and that is both a bad and a good thing. The good thing is that we have many options to choose from. However, the bad thing is that we do not know which resource is the best.
Thus, the purpose of thi...]]></description><link>https://codelounge.dev/5-best-resources-to-learn-javascript-for-free</link><guid isPermaLink="true">https://codelounge.dev/5-best-resources-to-learn-javascript-for-free</guid><category><![CDATA[JavaScript]]></category><category><![CDATA[100DaysOfCode]]></category><category><![CDATA[#codenewbies]]></category><dc:creator><![CDATA[CodeLounge]]></dc:creator><pubDate>Thu, 08 Apr 2021 18:41:43 GMT</pubDate><enclosure url="https://cdn.hashnode.com/res/hashnode/image/upload/v1617907278421/CJ3CkFl7O.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>There are countless resources to learn JavaScript, and that is both a bad and a good thing. The good thing is that we have many options to choose from. However, the bad thing is that we do not know which resource is the best.</p>
<p>Thus, the purpose of this article is to shine some light, and guide you towards the best resources to learn JavaScript. Especially as a beginner. Therefore, let us see the best resources.</p>
<hr />
<h1 id="freecodecamp">FreeCodeCamp</h1>
<p>The first resource on the list is FreeCodeCamp. FreeCodeCamp provides an excellent introduction to JavaScript. Moreover, it dives into advanced topics as well. It takes you from no knowledge to an intermediate level.</p>
<p>However, once you dive into the advanced topics, you might have to supplement the learning with additional resources. Or with their YouTube channel. By the way, talking about their YouTube channel, it is another excellent resource. They have many JavaScript tutorials created by professional developers.</p>
<p>Thus, you can get to an advanced level just by using the FreeCodeCamp platform and their YouTube channel.</p>
<p>Check:</p>
<ul>
<li><a target="_blank" href="https://www.freecodecamp.org/learn/">FreeCodeCamp curriculum</a></li>
<li><a target="_blank" href="https://www.youtube.com/channel/UC8butISFwT-Wl7EV0hUK0BQ">FreeCodeCamp YouTube channel</a></li>
</ul>
<hr />
<h1 id="you-dont-know-javascript">You Don’t Know JavaScript</h1>
<p>The book series “You Don’t Know JavaScript” is one of the best resources to learn JavaScript, if not the best. This series is split into six books, and it takes you from zero knowledge to an advanced level. It teaches you about the scope, closures, “this” keyword, object prototype, types &amp; grammar, async, performance, and ES6 &amp; beyond.</p>
<p>The series is written by Kyle Simpson, who is a very knowledgeable person, and an active JavaScript developer. The good thing is that, like FreeCodeCamp, YDKJS series is free. Of course, you can, and you should buy them to support the author if you can afford it.</p>
<p>The “You Don’t Know JavaScript” series is my go-to manual. Whenever I want to refresh concepts or learn new ones, I use this resource first. It is well-written, detailed, to the point, and always following the ECMAScript specification.</p>
<p>Check:</p>
<ul>
<li><a target="_blank" href="https://github.com/getify/You-Dont-Know-JS">You Don’t Know JavaScript</a></li>
</ul>
<hr />
<h1 id="javascript30">JavaScript30</h1>
<p>Practising by building application yourself is critical in programming. As a result, I want to recommend you JavaScript30, which focuses exclusively on building JavaScript applications. It does not use any frameworks, compilers, boilerplates, and so on. It is purely vanilla JavaScript.</p>
<p>The JavaScript30 course is for beginners and intermediate. It is going to teach you the JavaScript fundamentals and how to work with the Document Object Model (DOM). Bear in mind; you should already have basic JavaScript knowledge before starting the course. The purpose of the course is to make you apply that knowledge.</p>
<p>JavaScript30 is entirely free, as well. Until this point, you have three excellent resources to skyrocket your JavaScript skills for free!</p>
<p>Check:</p>
<ul>
<li><a target="_blank" href="https://javascript30.com/">JavaScript30</a></li>
</ul>
<hr />
<h1 id="mdn-web-docs-javascript">MDN Web Docs JavaScript</h1>
<p>MDN cannot miss from this article, as it is an excellent website. Thus, it is no surprise that their JavaScript tutorial is fantastic. </p>
<p>The online tutorial is split into four parts:</p>
<ol>
<li>Complete beginners</li>
<li>JavaScript Guide</li>
<li>Intermediate</li>
<li>Advanced</li>
</ol>
<p>As with the other resource listed in the article, you can go from a basic level to an advanced level. Besides that, the course is written and maintained by professional developers. </p>
<p>Therefore, you can bet on the tutorial provided by MDN. It is of the highest quality.</p>
<p>Check:</p>
<ul>
<li><a target="_blank" href="https://developer.mozilla.org/en-US/docs/Web/JavaScript">MDN JavaScript</a></li>
</ul>
<hr />
<h1 id="javascriptinfo">JavaScript.info</h1>
<p>The last resource I want to mention is JavaScript.info, which is a superb website for reference. It contains information on basic JavaScript, advanced concepts, and Document Object Model. </p>
<p>The website is split into three parts:</p>
<ol>
<li><strong>The JavaScript Language</strong> – start from scratch and go on to advanced concepts like OOP. The focus is on the language itself here.</li>
<li><strong>Browser: Document, Events, Interfaces</strong> – learn how to manage the browser page: add elements, manipulate their size and position, dynamically create interfaces and interact with the visitor.</li>
<li><strong>Additional Articles</strong> – a list of extra topics that assume you’ve covered the first two parts of the tutorial. There is no clear hierarchy here; you can read articles in the order you want.</li>
</ol>
<p>The information is dense, and to the point. You can use the website as your primary study guide, or you can use it in conjuncture with the other resources. </p>
<p>Check:</p>
<ul>
<li><a target="_blank" href="http://javascript.info/">JavaScript.info</a></li>
</ul>
<hr />
<h1 id="conclusion">Conclusion</h1>
<p>The list in this article is not exhaustive, but it covers some of the best resources to learn JavaScript. By using these resources, you can get to a pretty advanced level, and even get a job offer. For the best results, try to mix them because you can learn something from all of them.</p>
<p>And the best thing: they are entirely free (except for printed copies of YDKJS, which you can buy if you want to support the author).</p>
<blockquote>
<p>If you enjoyed the article, consider sharing it so more people can benefit from it! Also, feel free to @me on Twitter with your opinions.</p>
</blockquote>
]]></content:encoded></item><item><title><![CDATA[Top 5 Node.js/Express Tutorials For Beginners And Advanced Programmers]]></title><description><![CDATA[I am mainly building the back-end of my applications using Node.js and Express. As a result, I have done a lot of courses in this area. Thus, in this article, I want to present to you my favorite courses to learn Node.js and Express. 
They have varyi...]]></description><link>https://codelounge.dev/top-5-nodejsexpress-tutorials-for-beginners-and-advanced-programmers</link><guid isPermaLink="true">https://codelounge.dev/top-5-nodejsexpress-tutorials-for-beginners-and-advanced-programmers</guid><category><![CDATA[JavaScript]]></category><category><![CDATA[Node.js]]></category><category><![CDATA[100DaysOfCode]]></category><dc:creator><![CDATA[CodeLounge]]></dc:creator><pubDate>Wed, 07 Apr 2021 05:45:35 GMT</pubDate><enclosure url="https://cdn.hashnode.com/res/hashnode/image/upload/v1617774295006/-nzPoR7c7.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>I am mainly building the back-end of my applications using Node.js and Express. As a result, I have done a lot of courses in this area. Thus, in this article, I want to present to you my favorite courses to learn Node.js and Express. </p>
<p>They have varying difficulty, some being easier than others. Also, each course has its particularities. For instance, some teach you sessions; some do not. Therefore, they complement each other, even though there is an overlap between them.</p>
<p>Though, remember that nothing helps you more than building projects yourself. Follow the courses, and then put to use what you learned! Also, it's important to note that the courses are in no particular order. Without further ado, let's jump in.</p>
<hr />

<h1 id="mozilla-mdn-nodejsexpress-tutorial">Mozilla MDN Node.js/Express Tutorial</h1>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1606461183793/4U8REP3Az.png" alt="Screenshot 2020-11-27 at 09.12.38.png" />
Mozilla MDN is an excellent website with many tutorials, including a tutorial on Node.js and Express. In the tutorial, you learn the concepts by building an online library. The application allows users to add books, authors, and genres. It also shows what the books are written by each author, and to what genre they belong to.</p>
<p>But the question is - what do you learn in this tutorial? You learn:</p>
<ul>
<li>About Node and Express. What they are, how they work, and what their benefits are.</li>
<li>How to set-up a Node (Express) development environment.</li>
<li>To perform CRUD operations.</li>
<li>How to create relationships between data. (e.g. Authors and Books)</li>
<li>The MVC pattern - controllers, views, models, routes.</li>
<li>How to use MongoDB and Mongoose with Node.js and Express.</li>
<li>To create a front-end for your application using Pug.</li>
<li>How to deploy your application to production.</li>
</ul>
<p>Do not be fooled by the simplistic look of the application because the tutorial is not a design/front-end tutorial. The tutorial provides a lot of invaluable information on building a back-end application ready to deploy to production.</p>
<p>The verdict? I highly recommend the tutorial, and you can check it on the <a target="_blank" href="https://developer.mozilla.org/en-US/docs/Learn/Server-side/Express_Nodejs">MDN's website</a>.</p>
<hr />

<h1 id="freecodecamp-tutorial">FreecodeCamp Tutorial</h1>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1606463147274/jffvtiYF6.png" alt="FreeCodeCamp_logo.png" />
Another excellent tutorial on Node and Express is the tutorial from <a target="_blank" href="https://www.freecodecamp.org/learn">FreecodeCamp</a>. Similar to Mozilla MDN, the tutorial takes you from no knowledge on the subject to advanced concepts like authentication. Besides that, you are going to build multiple applications, not just one. Thus, there are lots of opportunities to practice what you learn.</p>
<p>Without further ado, let's see some of the things you learn by following FreecodeCamp's curriculum:</p>
<ul>
<li>Introduction to Node and Express.</li>
<li>Learn how to serve HTML files and static assets (images, CSS, JavaScript, and others).</li>
<li>Implement Middlewares.</li>
<li>Learn about Query/Route Parameters.</li>
<li>Get and parse data from POST requests.</li>
<li>Use MongoDB and Mongoose to store data in a database and manipulate it.</li>
<li>Set up authentication and authorization with Passport.</li>
<li>Implement CRUD operations.</li>
</ul>
<p>I extracted the most important topics, but the curriculum covers a lot more. Freecodecamp is a great way to get up and running with Node.js and Express. You would need to complete the material with other resources for advanced concepts and best practices, though.</p>
<p>To conclude, Freecodecamp is one of the best resources because you do not have to set up your environment. That means you can focus just on coding and not other things. Besides that, the information is valuable, and you can learn a lot of stuff for free.</p>
<hr />

<h1 id="the-complete-nodejs-developer-by-andrew-mead">The Complete Node.js Developer by Andrew Mead</h1>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1606465393281/E0fYnWul3.png" alt="Screenshot 2020-11-27 at 10.22.48.png" /></p>
<p>This course is one of the best to introduce you to the world of Node.js and Express. During this course, you build four web applications. Each application has a purpose, and it teaches you a handful of concepts. Thus, you learn a lot by building those four projects.</p>
<p>Some of the concepts you learn in this course are:</p>
<ul>
<li>Learning about Node.js Package Manager - NPM.</li>
<li>Designing a REST API.</li>
<li>Version Control with Git.</li>
<li>Uploading files and images.</li>
<li>Sending emails.</li>
<li>You also learn about ES6 and ES7.</li>
<li>How to authenticate users with JWT - JSON Web Token.</li>
<li>Testing with Jest.</li>
<li>Debugging with VS Code and Google Chrome.</li>
</ul>
<p>As usual, I highlighted the most important concepts you learn in the course. However, there are more concepts you learn. The course well-thought and you can use it to start with Node.js and Express or to fill gaps you have in your knowledge. The reason this course stands out is that the instructor goes into great detail about each concept. The explanations are not rushed, which makes it easier to follow along and learn better.</p>
<p>Do I recommend the course? Yes; I did the course twice, and I cannot recommend it enough. The course is suitable whether you are a beginner or an intermediate developer.</p>
<hr />

<h1 id="learn-node-by-wes-bos">Learn Node by Wes Bos</h1>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1606465082130/Dg9MpAz-t.png" alt="Screenshot 2020-11-27 at 10.17.34.png" /></p>
<p>From all the Node.js courses, the best-looking application you are going to build is in Wes Bos's course. The design of the application is catchy, beautiful and professional. </p>
<p>However, I want to mention I had troubles following the course in the beginning when I had no Node.js knowledge. I had to postpone it and follow another course to learn the basics. The course feels advanced, and there are other courses more suited for complete beginners. Though, keep in mind that this is my experience, and it might not be right for you.</p>
<p>Now let's see what this course covers, and you learn by following it. You learn how to:</p>
<ul>
<li>Implement CRUD operations.</li>
<li>Implement REST API points.</li>
<li>Use the MVC pattern for your application.</li>
<li>Add routing and pagination.</li>
<li>Implement file uploading.</li>
<li>Set up a templating engine like Pug.</li>
<li>Deploy to production, on various providers.</li>
<li>Send emails to users.</li>
<li>Storing data in a MongoDB database, and manipulating that data.</li>
<li>Implement authentication and authorization.</li>
</ul>
<p>As with the other courses, these are just some of the topics. The course covers a lot more topics, which you can find <a target="_blank" href="https://learnnode.com/">learnnode.com</a>.</p>
<p>Do I recommend the course? Yes. It's a great course where you learn a ton of concepts by building a real-world application. The only blocker might be that it's a paid course. Otherwise, it's an all-around great course.</p>
<hr />

<h1 id="nodejs-the-complete-guide-by-maximilian-schwarzmuller">NodeJS - The Complete Guide by Maximilian Schwarzmüller</h1>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1606491200402/rqLbiFi6Z.png" alt="Screenshot 2020-11-27 at 17.31.44.png" /></p>
<p>This Node.js course is a little bit different in the sense that it covers more topics than just Node.js and Express. Even though the focus is on these two technologies, you learn others too. For instance, it teaches TypeScript and Deno, which is a bonus. You get more than you paid for.</p>
<p>Besides the usual Node.js and Express concepts you learn, which are taught in the other courses too, you also learn:</p>
<ul>
<li>Vanilla JavaScript and ES6 concepts.</li>
<li>To use SQL with Node.js and Express.</li>
<li>Advanced authentication and testing.</li>
<li>What GraphQL is and how to use it.</li>
<li>How to add Stripe payments.</li>
</ul>
<p>As usual, these are not the only subjects. However, these are the concepts that differentiate the course from other courses. You get all the regular information about Node.js and Express, plus these other concepts and technologies.</p>
<p>The verdict? The course is worth its money. It goes well-beyond Node.js and Express, and it teaches you other cool and useful concepts and technologies. You can check the course <a target="_blank" href="https://www.udemy.com/course/nodejs-the-complete-guide/">here</a>.</p>
<hr />

<h1 id="conclusion">Conclusion</h1>
<p>These are the top five Node.js/Express courses I recommend. They can take you from no knowledge to an advanced level. Of course, I have to mention that these are not the only ones. Also, they are the top five based on my experience.</p>
<p>I recommend all courses from this article because you cannot go wrong with any of them. However, if you have more suggestions, feel free to leave them in the comments. I would like to see more good courses.</p>
]]></content:encoded></item><item><title><![CDATA[Top 16 Browser Extensions For Increased Developer Productivity]]></title><description><![CDATA[In this article, you can see the top 16 browser extensions for developers. This curated list of the best browser extensions aims to help improve your productivity and save you time.
If you find the article helpful, it would help us a lot if you could...]]></description><link>https://codelounge.dev/top-16-browser-extensions-for-increased-developer-productivity</link><guid isPermaLink="true">https://codelounge.dev/top-16-browser-extensions-for-increased-developer-productivity</guid><category><![CDATA[General Advice]]></category><category><![CDATA[Productivity]]></category><category><![CDATA[100DaysOfCode]]></category><dc:creator><![CDATA[CodeLounge]]></dc:creator><pubDate>Tue, 06 Apr 2021 06:06:47 GMT</pubDate><enclosure url="https://cdn.hashnode.com/res/hashnode/image/upload/v1617689194907/q6MPcRKG3.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>In this article, you can see the top 16 browser extensions for developers. This curated list of the best browser extensions aims to help improve your productivity and save you time.</p>
<p>If you find the article helpful, it would help us a lot if you could share it with others. If you do share it, tag us so we can see it! Thank you!</p>
<hr />
<h1 id="1-blocksitehttpschromegooglecomwebstoredetailblocksite-stay-focused-coeiimnmioipafcokbfikbljfdeojpcgbhhlen">1. <a target="_blank" href="https://chrome.google.com/webstore/detail/blocksite-stay-focused-co/eiimnmioipafcokbfikbljfdeojpcgbh?hl=en">BlockSite</a></h1>
<p>The "BlockSite" extension is excellent for blocking distractions and staying focused. It stops procrastination by allowing you to block distracting and harmful websites.</p>
<p>Each time you try to access a blocked website, you will get an error. Thus, are you addicted to social media websites? No problem! You can block them, so they do not distract you!</p>
<blockquote>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1617450462306/HVoEx3Of6.png" alt="Screenshot 2021-04-03 at 14.47.24.png" /></p>
</blockquote>
<p>The above image shows what you see when "BlockSite" runs and you try to access a blocked website. Also, you can whitelist certain websites and block all the others.</p>
<hr />
<h1 id="2-pomodoro-assistanthttpschromegooglecomwebstoredetailmarinara-pomodoroc2ae-assistlojgmehidjdhhbmpjfamhpkpodfcodefhlen">2. <a target="_blank" href="https://chrome.google.com/webstore/detail/marinara-pomodoro%C2%AE-assist/lojgmehidjdhhbmpjfamhpkpodfcodef?hl=en">Pomodoro Assistant</a></h1>
<p>If you are not aware of the Pomodoro technique, it's a time management method where you use a timer to break down work into intervals. Each work interval is 25 minutes in length, followed by a short break.</p>
<p>Thus, the Pomodoro extension allows you to use the Pomodoro technique. Of course, you can change the duration of the work intervals and breaks. Customize them as you see fit.</p>
<blockquote>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1617448628662/0GpSBqN0s.png" alt="Screenshot 2021-04-03 at 14.16.47.png" /></p>
</blockquote>
<p>The picture above shows the extension and how customizable it is! See how your productivity increases with this browser extension.</p>
<hr />
<h1 id="3-json-formatterhttpschromegooglecomwebstoredetailjson-formatterbcjindcccaagfpapjjmafapmmgkkhgoahlen">3. <a target="_blank" href="https://chrome.google.com/webstore/detail/json-formatter/bcjindcccaagfpapjjmafapmmgkkhgoa?hl=en">JSON Formatter</a></h1>
<p>Working with JSON data in the browser can be a nuisance, especially when there is a lot of data. The extension, <em>JSON Formatter</em>, displays the JSON data in a way that's easier to absorb and understand.</p>
<p>This extension provides features such as:</p>
<ul>
<li>clickable URLs</li>
<li>syntax highlighting</li>
<li>indentation</li>
<li>collapsible sections</li>
</ul>
<blockquote>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1617445064433/JYsNCS1di.png" alt="Screenshot 2021-04-03 at 13.17.34.png" /></p>
</blockquote>
<p>The above screenshot shows an example of using JSON Formatter. If you want to see how the raw data looks, without using a JSON extension, access <a target="_blank" href="https://api.github.com/users/catalinpit">this link</a> in your browser.</p>
<hr />
<h1 id="4-dailydevhttpschromegooglecomwebstoredetaildailydev-all-in-one-codinjlmpjdjjbgclbocgajdjefcidcncaiedhlen">4. <a target="_blank" href="https://chrome.google.com/webstore/detail/dailydev-all-in-one-codin/jlmpjdjjbgclbocgajdjefcidcncaied?hl=en">Daily.dev</a></h1>
<p>Daily Dev is a developer news aggregator that runs in the browser. Each time you open a new browser tab, you will get all the news from the developer world. It gathers news from more than 350 sources, and it's the easiest way to stay up-to-date with the latest tech news!</p>
<p>Why would you use this extension instead of other sources?</p>
<ul>
<li>it's effortless - you only have to install it in your browser, and you get all the news without any effort from your side</li>
<li>no registration needed - you do not have to register to use it or read the news</li>
<li>it's free</li>
</ul>
<blockquote>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1617445481777/yIxE7XeTK.png" alt="Screenshot 2021-04-03 at 13.24.17.png" /></p>
</blockquote>
<p>The screenshot above illustrates the extension in my browser. </p>
<hr />
<h1 id="5-clear-cachehttpschromegooglecomwebstoredetailclear-cachecppjkneekbjaeellbfkmgnhonkkjfpdnutmsourcechrome-ntp-icon">5. <a target="_blank" href="https://chrome.google.com/webstore/detail/clear-cache/cppjkneekbjaeellbfkmgnhonkkjfpdn?utm_source=chrome-ntp-icon">Clear Cache</a></h1>
<p>Sometimes you want to clear your browser cache, and you know that it takes a few clicks to do it. Luckily, there is a browser extension that allows you to clear your data with one click.</p>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1617446123892/UC-VCFFCN.png" alt="Screenshot 2021-04-03 at 13.35.04.png" /></p>
<p>The screenshot above illustrates a part of the application. You can see that you can customize what data to clear. You can choose between App Cache, Cache, Cookies, Downloads, File Systems, Form Data, History, Indexed DB, Local Storage, Plugin Data, Passwords and WebSQL.</p>
<p>Clear Cache extension improves your productivity because you can clear your cache in one click, eliminating multiple steps.</p>
<hr />
<h1 id="6-wappalyzerhttpschromegooglecomwebstoredetailwappalyzergppongmhjkpfnbhagpmjfkannfbllamg">6. <a target="_blank" href="https://chrome.google.com/webstore/detail/wappalyzer/gppongmhjkpfnbhagpmjfkannfbllamg">Wappalyzer</a></h1>
<p>Wappalyzer is a browser extension that allows you to see the technologies behind web sites and web applications. </p>
<p>With this extension, you can find the following information:</p>
<ul>
<li>the CMS used</li>
<li>the framework, e-commerce platform or JavaScript library used</li>
<li>payment processors</li>
<li>marketing and analytics tools</li>
</ul>
<blockquote>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1617446855941/48-ZOFvJg.png" alt="Screenshot 2021-04-03 at 13.47.21.png" /></p>
</blockquote>
<p>The image above illustrates the extension in action. The Wappalyzer shows the technologies used to build our blog - codelounge.dev.</p>
<hr />
<h1 id="7-open-in-vs-codehttpschromegooglecomwebstoredetailopen-in-vscodepfakkjlkpobjeghlgipljkjmbgcanpji">7. <a target="_blank" href="https://chrome.google.com/webstore/detail/open-in-vscode/pfakkjlkpobjeghlgipljkjmbgcanpji">Open in VS Code</a></h1>
<p>"Open in VS Code" is a handy feature that does just what the name says - it allows you to open Github and GitLab links in VS Code.</p>
<p>It's a huge time saver because it eliminates time-consuming steps such as downloading the files and manually opening them in VS Code. All you have to do is to right-click on the file and click on the option saying "Open in VS Code". The image below illustrates that.</p>
<blockquote>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1617448296157/tEy-A7oab.png" alt="Screenshot 2021-04-03 at 14.11.26.png" /></p>
</blockquote>
<hr />
<h1 id="8-cssviewerhttpschromegooglecomwebstoredetailcssviewerggfgijbpiheegefliciemofobhmofgce">8. <a target="_blank" href="https://chrome.google.com/webstore/detail/cssviewer/ggfgijbpiheegefliciemofobhmofgce">CSSViewer</a></h1>
<blockquote>
<p><img src="https://lh3.googleusercontent.com/7N4yJIzV9CwVOYgInp7qEWae4waxYHxwKfb6KahJn8q0ilEvxPwgdbI3zuM7iujZiR5JEgerZS1ail9Yr-Hpd1UJ=w640-h400-e365-rj-sc0x00ffffff" alt="css-viewer-example" /></p>
</blockquote>
<p>The "CSS Viewer" extension allows you to inspect elements from web sites and see their CSS properties. It's a time-saver because you can quickly see the CSS of elements rather than inspecting it and searching for the CSS separately.</p>
<p>You can see the "CSS Viewer" extension in action in the image above.</p>
<hr />
<h1 id="9-fake-fillerhttpschromegooglecomwebstoredetailfake-fillerbnjjngeaknajbdcgpfkgnonkmififhfohlen">9. <a target="_blank" href="https://chrome.google.com/webstore/detail/fake-filler/bnjjngeaknajbdcgpfkgnonkmififhfo?hl=en">Fake filler</a></h1>
<p>Sometimes, when you test your applications, you need to enter dummy information into forms. Rather than completing the forms manually, why not use the "Fake filler" extensions which does that for you automatically?</p>
<p>This browser extension saves you a lot of time, as it completes the fields with random data within seconds. It's a true time-saver, and I highly recommend it! You can see it in the figure below.</p>
<blockquote>
<p><img src="https://lh3.googleusercontent.com/i0MlgdmwpHH8FU6e7NsEd6ykGCpI48vRn36RgEe4ZggPJpJvNPNVs3Ay64LU0KlS06ed1Ez6Hl0DG40lEbSnq-hkuiQ=w640-h400-e365-rj-sc0x00ffffff" alt="fake-filler-example" /></p>
</blockquote>
<hr />
<h1 id="10-devohttpschromegooglecomwebstoredetaildevoelkhalpmbmbaeoemecpcfdcoekmpgmdmhlen">10. <a target="_blank" href="https://chrome.google.com/webstore/detail/devo/elkhalpmbmbaeoemecpcfdcoekmpgmdm?hl=en">Devo</a></h1>
<p>Devo is a browser extension that helps you to stay up-to-date with the latest dev news! This browser extension curates information from sources such as:</p>
<ul>
<li>GitHub trending</li>
<li>Hacker News</li>
<li>Product Hunt</li>
</ul>
<p>And many more. You can see the extension in the picture below.</p>
<blockquote>
<p><img src="https://lh3.googleusercontent.com/dPTEBjHkD224Kfr_nokQOwQN3mgLI_IElE1-68QT_L1KkKbxYZtYB-JmfMPjjtpXz0VSCUZSE0ikERnXY_zdeMWI=w640-h400-e365-rj-sc0x00ffffff" alt="devo-example" /></p>
</blockquote>
<p><strong>Note</strong>: It's important to note that you cannot use Devo and Daily Dev at the same time. You have to choose between them. Also, if you would ask me, I prefer the Daily Dev extension rather than this one.</p>
<hr />
<h1 id="13-lorem-ipsum-generatorhttpschromegooglecomwebstoredetaillorem-ipsum-generator-defmcdcbjjoakogbcopinefncmkcamnfkdbhlen">13. <a target="_blank" href="https://chrome.google.com/webstore/detail/lorem-ipsum-generator-def/mcdcbjjoakogbcopinefncmkcamnfkdb?hl=en">Lorem Ipsum Generator</a></h1>
<p>There are various use cases where you might want a big chunk of placeholder text. Luckily, the "Lorem Ipsum Generator" can help with that!</p>
<p>This browser extension allows you to generate random text between 1 to 5 paragraphs and 1 to 20 sentences per paragraph.</p>
<blockquote>
<p><img src="https://lh3.googleusercontent.com/xWh8HFLHecrg_MFE8T1P5jU19aPMR4WkphJFmHHbuxzs7Ls-nX1Zn9QCY4WrGZIg24PK4Oel1oJeFAyST-WqhVvu77w=w640-h400-e365-rj-sc0x00ffffff" alt="lorem-ipsum-generator" /></p>
</blockquote>
<p>The image above illustrates the extension in actions. It's super handy when you have to use placeholder text!</p>
<hr />
<h1 id="14-web-developer-checklisthttpschromegooglecomwebstoredetailweb-developer-checklistiahamcpedabephpcgkeikbclmaljebjprelatedhlen">14. <a target="_blank" href="https://chrome.google.com/webstore/detail/web-developer-checklist/iahamcpedabephpcgkeikbclmaljebjp/related?hl=en">Web Developer Checklist</a></h1>
<p>The "Web Developer Checklist" extension analyses web pages and checks for violations of best practices. It's a convenient tool that allows web developers to discover problems with any website on the internet.</p>
<blockquote>
<p><img src="https://lh3.googleusercontent.com/_VbCSLIclZWz224bZ_oveL973yA0W4viSqPmqoX2IslHc6lqBWDZeDkREy4xOiCaI_KaJHyWwPHJunRcnURy8nXn=w640-h400-e365-rj-sc0x00ffffff" alt="web-dev-checklist" /></p>
</blockquote>
<p>All you have to do is install the extension and then run it on any websites you want to check. Depending on the website, it will tell you what the issues are and how can they be improved or fixed. If you care about SEO, speed, accessibility, and so on, you want this extension!</p>
<hr />
<h1 id="15-editthiscookiehttpschromegooglecomwebstoredetaileditthiscookiefngmhnnpilhplaeedifhccceomclgfbg">15. <a target="_blank" href="https://chrome.google.com/webstore/detail/editthiscookie/fngmhnnpilhplaeedifhccceomclgfbg">EditThisCookie</a></h1>
<p>This browser extension is a cookie manager that allows you to do the following with cookies:</p>
<ul>
<li>add</li>
<li>delete</li>
<li>edit</li>
<li>search</li>
<li>protect &amp; block</li>
</ul>
<p>"EditThisCookie" is one of the most popular cookie managers, with 2,000,000+ downloads and 4.5 out of 5 stars (rated by 11,450 people). Besides that, it's Open Source <em>(you can contribute to it)</em> and it supports over twenty languages. I highly recommend it!</p>
<blockquote>
<p><img src="https://lh3.googleusercontent.com/jyNAq1Q5WW8Wk62OxxR5BmhBLQzToNSEY4rtKfi0x2bYLiUBKLZKJLvms5GyurG90Dod6IADYazw-0bkKFUi_fmF=w640-h400-e365-rj-sc0x00ffffff" alt="cookie-manager" /></p>
</blockquote>
<p>The above image illustrates an example with some of its features.</p>
<hr />
<h1 id="16-quickcodehttpschromegooglecomwebstoredetailquickcode-free-online-pronnigpbiaggiephcndokoaongeefpbdcjhlen">16. <a target="_blank" href="https://chrome.google.com/webstore/detail/quickcode-free-online-pro/nnigpbiaggiephcndokoaongeefpbdcj?hl=en">QuickCode</a></h1>
<p>The "QuickCode" browser extension curates free online programming courses and displays them in your browser tab! It includes lessons from companies/platforms/Universities such as Udacity, Coursera, Udemy, EDX and many more.</p>
<p>You can also browser courses by the programming language. You can choose from Java, Python, JavaScript, Node, Vue, and many more! The figure below shows the extension!</p>
<blockquote>
<p><img src="https://lh3.googleusercontent.com/1wAIICr-Lojc5zNRYnNw6hxoNkoXdhltYD8tNf_wnvXHbYhkme5ZlAGhsrB5LM1-Dcceks8GWD4-Ujrgf6eZpIt2NQ=w640-h400-e365-rj-sc0x00ffffff" alt="quickcode-screenshot" /></p>
</blockquote>
<hr />
<h1 id="conclusion">Conclusion</h1>
<p>These browser extensions are helpful, and they increase your productivity! However, the list is not exhaustive, so feel free to add more in the comments!</p>
<p>We're looking forward to seeing other suggestions!</p>
<p>Also, it's important to note that some might be available for other browsers, whereas some might not! The browser extensions from this article are recommended for the Chrome browser. However, most of them are available in other browsers too!</p>
]]></content:encoded></item><item><title><![CDATA[Getting Started With The GitHub’s REST API]]></title><description><![CDATA[There are projects where you need to manage data not coming from a regular database but rather from sources such as repositories. In situations like this, you need to integrate with various service providers (GitHub, GitLab, etc.)
While there are mul...]]></description><link>https://codelounge.dev/getting-started-with-the-githubs-rest-api</link><guid isPermaLink="true">https://codelounge.dev/getting-started-with-the-githubs-rest-api</guid><category><![CDATA[GitHub]]></category><category><![CDATA[General Advice]]></category><category><![CDATA[100DaysOfCode]]></category><dc:creator><![CDATA[CodeLounge]]></dc:creator><pubDate>Mon, 05 Apr 2021 09:07:38 GMT</pubDate><enclosure url="https://cdn.hashnode.com/res/hashnode/image/upload/v1617613615885/sfP1uUlC5.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>There are projects where you need to manage data not coming from a regular database but rather from sources such as repositories. In situations like this, you need to integrate with various service providers (GitHub, GitLab, etc.)</p>
<p>While there are multiple ways to go around this topic, today, I will focus on how to do that using GitHub's REST API. For this task, I chose to play with the integration using a pre-existent Node JS app. </p>
<p>You will find only the integration logic in the code snippets below rather than a full-fledged working app.</p>
<h1 id="getting-started">Getting started</h1>
<p>The first thing I did was install GitHub's library, <a target="_blank" href="https://octokit.github.io/rest.js/v18/">Octokit REST</a> is one of the libraries you can use for this. An alternative to this is <a target="_blank" href="https://github.com/octokit/core.js/">Octokit Core</a> (more functionalities; yet these are not required for what I'm trying to achieve today). </p>
<p>Once installed, I generated a personal access token. This one is needed for making the requests. To generate a token, go to <a target="_blank" href="https://github.com/settings/tokens">Personal Access Tokens</a> page on GitHub and simply add a new one to the list (only select <code>repo</code>).</p>
<p>The last thing I did before getting into the action was to fork <a target="_blank" href="https://github.com/octocat/Hello-World">this repo</a>.</p>
<h1 id="connecting-to-your-repository">Connecting to your Repository</h1>
<p>With all of the pre-requisites ready, I created a new <code>.js</code> file using the configs below.</p>
<pre><code><span class="hljs-keyword">const</span> { Octokit } = <span class="hljs-keyword">require</span>(<span class="hljs-string">'@octokit/rest'</span>);
<span class="hljs-keyword">const</span> octokit = <span class="hljs-keyword">new</span> Octokit({
    auth: <span class="hljs-string">'my-personal-access-token'</span>,
});

<span class="hljs-keyword">const</span> owner = <span class="hljs-string">'my-username'</span>;
<span class="hljs-keyword">const</span> repo = <span class="hljs-string">'Hello-World'</span>;
author = {
    name: <span class="hljs-string">'My Name'</span>,
    email: <span class="hljs-string">'myemail@domain.com'</span>,
};
<span class="hljs-keyword">const</span> url =  <span class="hljs-string">'/repos/{owner}/{repo}/{path}'</span>; <span class="hljs-comment">// leave this as is</span>
<span class="hljs-keyword">const</span> ref =  <span class="hljs-string">'heads/master'</span>; <span class="hljs-comment">// 'master' represents the name of my primary branch</span>
</code></pre><p>I then authenticated a new <code>octokit</code> instance, used to make calls to GitHub. The rest of the configs were needed on a global scope for various actions (more on that, down below).</p>
<h1 id="pulling-data">Pulling data</h1>
<p>Easiest thing to do with the current setup is to retrieve the contents of the repo. To do that, I created a new function where I made a request to octokit, specifying the path of the wanted content:</p>
<pre><code><span class="hljs-keyword">const</span> getContents = <span class="hljs-keyword">async</span> () =&gt; {
    <span class="hljs-keyword">const</span> { data } = <span class="hljs-keyword">await</span> octokit.request({
        owner,
        repo,
        url,
        method: <span class="hljs-string">'GET'</span>,
        path: <span class="hljs-string">'contents'</span>, <span class="hljs-comment">// gets the whole repo</span>
    });
    console.log(data)
}

getContents();
</code></pre><p>Et voila! The request returns a list with one object corresponding to the README file from the forked repo. If I had a more complex structure in the repo and wanted to retrieve data from a specific folder, I could have changed the path to something like this: 'contents/src/components/component1'; where <code>src</code> is at the root and <code>component1</code> contains one or more files.</p>
<p>Going back to my object, we can see that it contains information such as links, name, path &amp; type of the file, and a property <code>sha</code>. This represents the hash of the file, and you can think of it as an ID.  SHAs play a significant role when it comes to working with this API, so you'll see that property being used over and over again.</p>
<pre><code>[
  {
    <span class="hljs-type">name</span>: <span class="hljs-string">'README'</span>,
    <span class="hljs-type">path</span>: <span class="hljs-string">'README'</span>,
    sha: <span class="hljs-string">'980a0d5f19a64b4b30a87d4206aade58726b60e3'</span>,
    size: <span class="hljs-number">13</span>,
    url: <span class="hljs-string">'https://api.github.com/repos/my-username/Hello-World/contents/README?ref=master'</span>,
    html_url: <span class="hljs-string">'https://github.com/my-username/Hello-World/blob/master/README'</span>,
    git_url: <span class="hljs-string">'https://api.github.com/repos/my-username/Hello-World/git/blobs/980a0d5f19a64b4b30a87d4206aade58726b60e3'</span>,
    download_url: <span class="hljs-string">'https://raw.githubusercontent.com/my-username/Hello-World/master/README'</span>,
    <span class="hljs-keyword">type</span>: <span class="hljs-string">'file'</span>,
    _links: {
      self: <span class="hljs-string">'https://api.github.com/repos/my-username/Hello-World/contents/README?ref=master'</span>,
      git: <span class="hljs-string">'https://api.github.com/repos/my-username/Hello-World/git/blobs/980a0d5f19a64b4b30a87d4206aade58726b60e3'</span>,
      html: <span class="hljs-string">'https://github.com/my-username/Hello-World/blob/master/README'</span>
    }
  }
]
</code></pre><h1 id="pushing-data">Pushing data</h1>
<p>Now, if I want to push a file to the repo, things get complicated.  To do that, I need to:</p>
<ul>
<li>make sure I'm "up to date" with the branch I'm on (currently <code>master</code>) by getting the latest commit (<code>git pull</code>)</li>
<li>create a new list of files that will be added to the commit (<code>git add .</code>)</li>
<li>create a new commit (<code>git commit</code>)</li>
<li>push the changes (<code>git push origin HEAD</code>)</li>
</ul>
<p>The way to achieve is by first pulling the data. To do that, I got the ref to the latest commit:</p>
<pre><code><span class="hljs-keyword">const</span> pushContents = <span class="hljs-keyword">async</span> () =&gt; {
    <span class="hljs-keyword">const</span> commits = <span class="hljs-keyword">await</span> octokit.repos.listCommits({
        owner,
        repo,
    });

    <span class="hljs-keyword">const</span> latestCommitSHA = commits.data[<span class="hljs-number">0</span>].sha;
}
</code></pre><p>Only the SHA of the latest commit is needed, so I extracted it from the <code>commits</code> variable.</p>
<p>Next, I faked the files which are going to be committed. These are later added to a <code>git tree</code> (the hierarchy structure between files in a Git repository). For that, I followed the format <a target="_blank" href="https://docs.github.com/en/rest/reference/git#create-a-tree">implied by the API</a>.</p>
<pre><code><span class="hljs-keyword">const</span> pushContents = <span class="hljs-keyword">async</span> () =&gt; {
    ...
    <span class="hljs-keyword">const</span> files = [{
        mode: <span class="hljs-string">'100644'</span>,
        path: <span class="hljs-string">'src/file1.txt'</span>,
        content: <span class="hljs-string">'Hello world 1'</span>, <span class="hljs-comment">//whatever</span>
    },{
        mode: <span class="hljs-string">'100644'</span>,
        path: <span class="hljs-string">'src/file2.txt'</span>,
        content: <span class="hljs-string">'Hello world 2'</span>,
    }];
}
</code></pre><p>The format above explained: </p>
<ul>
<li>mode: type of the item, 100644 = file</li>
<li>path: location, name and extension of the file </li>
<li>content: this one is optional, whatever you want to add inside the file (if the file already has content, you'll need to <a target="_blank" href="https://octokit.github.io/rest.js/v18/#git-create-blob">create a blob</a>)</li>
</ul>
<p>With the files set, I went ahead and created the <code>tree</code>.</p>
<pre><code><span class="hljs-keyword">const</span> pushContents = <span class="hljs-keyword">async</span> () =&gt; {
    ...
    <span class="hljs-keyword">const</span> {
        data: { sha: treeSHA },
    } =  <span class="hljs-keyword">await</span> octokit.git.createTree({
        owner,
        repo,
        tree: files,
        base_tree: latestCommitSHA,
    });
}
</code></pre><p>The tree needs to include the files and the <code>sha</code> of my latest commit (to keep track of the data existing inside the repo). If you want to overwrite the repo completely, omit <code>base_tree</code>.</p>
<p>With the new tree in place, I created a new commit. I specified the <code>sha</code> of the tree, the <code>sha</code> of the latest commit, and my commit message. Without specifying the latest commit in <code>parents</code>, it is like trying to push without being up to date.</p>
<pre><code><span class="hljs-keyword">const</span> pushContents = <span class="hljs-keyword">async</span> () =&gt; {
    ...
    <span class="hljs-keyword">const</span> {
        data: { sha: newCommitSHA },
    } =  <span class="hljs-keyword">await</span> octokit.git.createCommit({
        owner,
        repo,
        author,
        tree: treeSHA,
        message: <span class="hljs-string">'Changes via API'</span>,
        parents: [latestCommitSHA],
    });
}
</code></pre><p>Once I had the commit ready, the only thing left to do was to push the changes.</p>
<pre><code><span class="hljs-keyword">const</span> pushContents = <span class="hljs-keyword">async</span> () =&gt; {
    ...
    <span class="hljs-keyword">const</span> response = <span class="hljs-keyword">await</span> octokit.git.updateRef({
        owner,
        repo,
        ref,
        sha: newCommitSHA,
    });
}
</code></pre><p>Done! Two new files have been added to my repo, under the folder <code>src</code>. Below you can find the full example:</p>
<pre><code><span class="hljs-keyword">const</span>  pushFiles  =  <span class="hljs-keyword">async</span> () =&gt; {
    <span class="hljs-comment">//git pull</span>
    <span class="hljs-keyword">const</span> commits =  <span class="hljs-keyword">await</span> octokit.repos.listCommits({
        owner,
        repo,
    });

    <span class="hljs-keyword">const</span> latestCommitSHA = commits.data[<span class="hljs-number">0</span>].sha;

    <span class="hljs-comment">// make changes</span>
    <span class="hljs-keyword">const</span> files = [{
        mode: <span class="hljs-string">'100644'</span>,
        path: <span class="hljs-string">'src/file1.txt'</span>,
        content: <span class="hljs-string">'Hello world 1'</span>, <span class="hljs-comment">//whatever</span>
    },{
        mode: <span class="hljs-string">'100644'</span>,
        path: <span class="hljs-string">'src/file2.txt'</span>,
        content: <span class="hljs-string">'Hello world 2'</span>,
    }];

    <span class="hljs-comment">// git add .</span>
    <span class="hljs-keyword">const</span> {
        data: { sha: treeSHA },
    } =  <span class="hljs-keyword">await</span> octokit.git.createTree({
        owner,
        repo,
        tree: files,
        base_tree: latestCommitSHA,
    });

    <span class="hljs-comment">// git commit -m 'Changes via API'</span>
    <span class="hljs-keyword">const</span> {
        data: { sha: newCommitSHA },
    } =  <span class="hljs-keyword">await</span> octokit.git.createCommit({
        owner,
        repo,
        author,
        tree: treeSHA,
        message: <span class="hljs-string">'Changes via API'</span>,
        parents: [latestCommitSHA],
    });

    <span class="hljs-comment">// git push origin HEAD</span>
    <span class="hljs-keyword">const</span> result = <span class="hljs-keyword">await</span> octokit.git.updateRef({
        owner,
        repo,
        ref,
        sha: newCommitSHA,
    });
};
</code></pre><h1 id="next-steps">Next steps</h1>
<p>Updating the existing files or deleting ones follows the same principle. To do that, target the tree, add what's changed, then commit and push. For easiness, make a function out of each step you need to go through, which return the SHAs.</p>
]]></content:encoded></item><item><title><![CDATA[Companies And Publications That Pay You To Write Technical Articles]]></title><description><![CDATA[There are publications and companies that pay people to write articles for their blogs. Thus, by writing articles for others, you can make some pocket money or even a full-time income. It all depends on how much time you are willing to put into writi...]]></description><link>https://codelounge.dev/companies-and-publications-that-pay-you-to-write-technical-articles</link><guid isPermaLink="true">https://codelounge.dev/companies-and-publications-that-pay-you-to-write-technical-articles</guid><category><![CDATA[General Advice]]></category><category><![CDATA[100DaysOfCode]]></category><dc:creator><![CDATA[CodeLounge]]></dc:creator><pubDate>Fri, 02 Apr 2021 07:32:43 GMT</pubDate><enclosure url="https://cdn.hashnode.com/res/hashnode/image/upload/v1617348750822/d-nzWe_QX.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>There are publications and companies that pay people to write articles for their blogs. Thus, by writing articles for others, you can make some pocket money or even a full-time income. It all depends on how much time you are willing to put into writing articles!</p>
<p>Therefore, in this article, you can see a handful of websites that pay you to write technical articles for them. You can see their name, the URL, and the approximate sum they pay you.</p>
<h1 id="websites-that-pay-for-technical-articles">Websites that pay for technical articles</h1>
<p>These companies/publications pay from $100 to $800 per article. It depends on the topic of the article, the complexity and the level of knowledge. </p>
<p>If you are just starting out with technical writing, I recommend pitching companies that pay at the lower end because you are more likely to get the gig! Publications that pay more for articles, usually have higher requirements. However, that does not mean you should do it that way! Approach any publication you want, and shoot your shot.</p>
<p>Thus, let's see the websites you can pitch to write for them.</p>
<hr />
<ul>
<li><p><strong><a target="_blank" href="https://go.twilio.com/twilio-voices/">Twilio</a></strong></p>
<ul>
<li>Up to $500 per article</li>
<li>You are not required to use Twilio. You need to write articles with examples, though.</li>
</ul>
</li>
<li><p><strong><a target="_blank" href="https://testdriven.io/blog/">TestDriven Io</a></strong></p>
<ul>
<li>Up to $500 per article</li>
<li>Web development tutorials designed to teach critical skills needed to test, launch, scale, and optimize applications.</li>
</ul>
</li>
<li><p><strong><a target="_blank" href="https://blog.hasura.io/the-hasura-technical-writer-program/">Hasura</a></strong></p>
<ul>
<li>Up to $300 per article</li>
<li>Articles including Hasura or GraphQL.</li>
</ul>
</li>
<li><p><strong><a target="_blank" href="https://www.digitalocean.com/community/pages/write-for-digitalocean">Digital Ocean</a></strong></p>
<ul>
<li>Up to $400 per article</li>
<li>Articles about OSS, infrastructure, cloud hosting, Linux, and more. It's not limited to their products, though!</li>
</ul>
</li>
<li><p><strong><a target="_blank" href="https://auth0.com/apollo-program">Auth0</a></strong></p>
<ul>
<li>Up to $300 per article</li>
<li>You pick topics from a list of possible articles.</li>
</ul>
</li>
<li><p><strong><a target="_blank" href="https://docs.google.com/document/d/1DZ9Hj8AcNfHI6bC4bfTDIFRNIIFnda6Mkj_n_4x3hWw/edit">Soshace</a></strong></p>
<ul>
<li>Up to $100 per article</li>
<li>You pick topics from a list of possible articles.</li>
</ul>
</li>
<li><p><strong><a target="_blank" href="https://css-tricks.com/guest-posting/">CSS-Tricks</a></strong></p>
<ul>
<li>Up to $250 per article</li>
<li>They have a <a target="_blank" href="https://www.notion.so/Writing-for-CSS-Tricks-0224d13de0b4421dadc667dddf512fc6">list of possible topics</a>. However, you can submit yours as well!</li>
</ul>
</li>
<li><p><strong><a target="_blank" href="https://www.wphub.com/write-for-us/">WPHub</a></strong></p>
<ul>
<li>Up to $200 per article</li>
<li>Tutorials about Wordpress.</li>
</ul>
</li>
<li><p><strong><a target="_blank" href="https://www.tutorialspoint.com/about/tutorials_writing.htm">Tutorialspoint</a></strong></p>
<ul>
<li>Up to $500 per article</li>
<li>Various technical topics. You can pick from a list of topics.</li>
</ul>
</li>
<li><p><strong><a target="_blank" href="https://fauna.com/blog/write-with-fauna">Fauna</a></strong></p>
<ul>
<li>Up to $500 per article</li>
<li>Content focused on technical education for topics related to application development and Fauna, with working sample code, wherever applicable. They have a list of possible topics.</li>
</ul>
</li>
<li><p><strong><a target="_blank" href="https://www.smashingmagazine.com/write-for-us/">Smashing Magazine</a></strong></p>
<ul>
<li>Unknown (In 2016 they paid up to $250)</li>
<li>You can submit tutorials, guides and case studies. </li>
</ul>
</li>
<li><p><strong><a target="_blank" href="https://code.tutsplus.com/articles/call-for-authors-write-for-tuts--cms-22034">Code Tuts+</a></strong></p>
<ul>
<li>$100 for tips, and $250 for tutorials</li>
<li>Pick from a list of possible articles.</li>
</ul>
</li>
<li><p><strong><a target="_blank" href="https://developer.nexmo.com/spotlight/">Vonage</a></strong></p>
<ul>
<li>Up to $500 per article</li>
<li>Technical tutorials.</li>
</ul>
</li>
<li><p><strong><a target="_blank" href="https://circleci.com/blog/guest-writer-program/">CircleCI</a></strong></p>
<ul>
<li>Up to $300 per article</li>
<li>You can pick from a list of possible topics.</li>
</ul>
</li>
<li><p><strong><a target="_blank" href="https://clubhouse.io/clubhouse-write-earn-give-program/">Clubhouse Io</a></strong></p>
<ul>
<li>Up to $600 per article</li>
<li>Pick from a list of possible topics. Technical tutorials, and how-to guides.</li>
</ul>
</li>
<li><p><strong><a target="_blank" href="https://www.typingdna.com/guest-author-program">TypingDNA</a></strong></p>
<ul>
<li>Up to $500 per article</li>
<li>Technical articles/tutorials related to TypingDNA.</li>
</ul>
</li>
<li><p><strong><a target="_blank" href="https://blog.logrocket.com/become-a-logrocket-guest-author-7d970eb673f9/">LogRocket</a></strong></p>
<ul>
<li>Up to $350 per article</li>
<li>Technical articles about Front-end. Tutorials on React, Redux, Vue.js, webpack, Wasm, MobX, GraphQL, JavaScript, etc. Frontend development best practices. Product/UI/UX design</li>
</ul>
</li>
<li><p><strong><a target="_blank" href="https://draft.dev/#write">Draft</a></strong></p>
<ul>
<li>Up to $500 per article</li>
<li>Choose for a list of possible topics</li>
</ul>
</li>
</ul>
<hr />
<h1 id="conclusion">Conclusion</h1>
<p>In the article, you can see some of the most popular publications. However, it's not an exhaustive list and new resources will be added or removed. Subscribe to the newsletter <em>(from the beginning of the post)</em> to stay updated!</p>
<p>Therefore, writing technical articles is a great way to create an additional income. I hope this article helps you!</p>
<blockquote>
<p>If you enjoyed the article, consider sharing it so more people can benefit from it!</p>
</blockquote>
]]></content:encoded></item><item><title><![CDATA[10 Programming Project Ideas For Beginners]]></title><description><![CDATA[Nothing beats practice, especially when you learn to code. Building one project teaches you more than watching multiple tutorials.
As a result, in this article, you can see a handful of programming projects suited to beginners.
If you are learning Ja...]]></description><link>https://codelounge.dev/10-programming-project-ideas-for-beginners</link><guid isPermaLink="true">https://codelounge.dev/10-programming-project-ideas-for-beginners</guid><category><![CDATA[General Programming]]></category><category><![CDATA[100DaysOfCode]]></category><category><![CDATA[General Advice]]></category><category><![CDATA[#codenewbies]]></category><dc:creator><![CDATA[CodeLounge]]></dc:creator><pubDate>Fri, 02 Apr 2021 04:39:07 GMT</pubDate><enclosure url="https://cdn.hashnode.com/res/hashnode/image/upload/v1617338312666/UblD6BmEk.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>Nothing beats practice, especially when you learn to code. Building one project teaches you more than watching multiple tutorials.</p>
<p>As a result, in this article, you can see a handful of programming projects suited to beginners.</p>
<p>If you are learning JavaScript or want to deepen your knowledge, I recommend checking my favourite course - <strong><a target="_blank" href="https://catalins.tech/jsprojects">JavaScript Web Projects</a></strong>.</p>
<h1 id="1-string-reversal-application">1. String reversal application</h1>
<p>For this project, you could create a simple web application that allows you to enter a string. After you enter the string, the application should display back the reversed string.</p>
<p>For instance, if you enter the string <code>"project"</code>, it should return <code>"tcejorp"</code>.  Such an application is beneficial because, in some interviews, they ask candidates to reverse a string. Thus, the project it's a great practice!</p>
<h1 id="2-binary-to-decimal-converter">2. Binary to decimal converter</h1>
<p>Another project you could create is a binary-to-decimal converter. Additionally, you can customize your algorithm to accept the reverse as well - decimal to binary.</p>
<p>The converter should allow the users to enter strings of up to 8 binary digits, 0's and 1's, in any sequence. After that, it should display the equivalent decimal number.</p>
<h1 id="3-palindrome-application">3. Palindrome application</h1>
<p>A palindrome is a word that reads the same backward as forward. There are some popular palindromes such as:</p>
<ul>
<li>Madam, I'm Adam</li>
<li>Never odd or even</li>
<li>Madam</li>
<li>Racecar</li>
</ul>
<p>Thus, try to write an algorithm that takes a string and checks if it's a palindrome or not. If it is a palindrome, return it. To make it more interesting, you could create a web application that everyone can access.</p>
<p>Writing such an algorithm is super useful because you might encounter it in coding interviews.</p>
<h1 id="4-weather-application">4. Weather application</h1>
<p>Building a weather application is a great way to practise working with APIs. Firstly, try to find a free API that allows you to fetch data. Then, use the API to display the weather forecast for a given city.</p>
<p>For instance, it should allow the user to input a city like <code>London</code> and then return the:</p>
<ul>
<li>temperature</li>
<li>wind speed</li>
<li>weather icon (e.g. sunny, windy, rain, etc.)</li>
</ul>
<p>Of course, you can display more information, but for the beginning, these are sufficient! Building a weather application helped me a lot when I learnt Vanilla JavaScript and React!</p>
<h1 id="5-vowels-counter">5. Vowels counter</h1>
<p>The name says it all - build an application that allows people to enter a string and then return the number of vowels.</p>
<p>The project teaches you essential concepts, and especially how to work with strings. I highly recommend it!</p>
<h1 id="6-calculator">6. Calculator</h1>
<p>A great way to learn and practise DOM manipulation is by building a JavaScript calculator. Besides that, you can practise your CSS skills to stylize it.</p>
<p>Your calculator should support the basic operations:</p>
<ul>
<li>adding numbers</li>
<li>subtracting numbers</li>
<li>dividing numbers</li>
<li>multiplying numbers</li>
</ul>
<h1 id="7-alarm-clock">7. Alarm clock</h1>
<p>Building an alarm clock would help you get more comfortable with the command line. You could create a simple application that accepts two command-line arguments:</p>
<ol>
<li>when to go off (what hour)</li>
<li>a YouTube link to an alarm clock sound</li>
</ol>
<p>After the alarm clock goes off, it should open the YouTube link you specified!</p>
<h1 id="8-list-the-capital-city">8. List The Capital City</h1>
<p>Build a project that allows people to enter the name of a country and then returns the capital city. For instance, if I enter my country - Romania, it should return the city Bucharest, because that is the capital.</p>
<p>You can use the <a target="_blank" href="https://en.wikipedia.org/wiki/List_of_national_capitals">list of national capitals</a> from Wikipedia for your application. </p>
<h1 id="9-pomodoro-clock">9. Pomodoro clock</h1>
<p>The Pomodoro technique is an excellent time management method. If you never heard about it until now, you can read more about it <a target="_blank" href="https://en.wikipedia.org/wiki/Pomodoro_Technique">here</a>. It's a great project to kill two birds with one stone - improve your time management, and practice your programming skills. </p>
<p>Your application should allow people to start, pause, stop and reset the timer. Also, the user should be able to set a timer with any number of minutes, which represents the <strong>focus</strong> session. Once the focus session is done, the clock should ring and start a <strong>break session</strong>. The break session should be 5 minutes.</p>
<h1 id="10-dollars-to-cents">10. Dollars to cents</h1>
<p>Converting dollars to cents is a coding problem you can come across in coding interviews. I even came across one.</p>
<p>Your application should allow people to enter a value such as $4.98 and return the cents. In this case, it would be 498 cents. This project enables you to practice fundamental programming concepts such as loops and if conditions, for instance.</p>
<h1 id="conclusion">Conclusion</h1>
<p>These ten projects are great to practise your programming skills. Of course, the list is not exhaustive, and there are other projects you can build. I'd be more than happy to see some of your recommendations in the comments!</p>
<p>To recap, some of the projects you can build are as follows:</p>
<ul>
<li>String reversal application</li>
<li>Binary to decimal converter</li>
<li>Palindrome application</li>
<li>Weather application</li>
<li>Vowels counter</li>
<li>Calculator</li>
<li>Alarm clock</li>
<li>List The Capital City</li>
<li>Pomodoro clock</li>
<li>Dollars to cents</li>
</ul>
]]></content:encoded></item><item><title><![CDATA[The Best 20 Places To Learn How To Code For Free]]></title><description><![CDATA[There are a plethora of resources to learn how to code for free. However, the question is - which ones are worth using? As a result, this article shows you the best places to learn how to code for free. 
1. freeCodeCamp
freeCodeCamp is one of the mos...]]></description><link>https://codelounge.dev/the-best-20-places-to-learn-how-to-code-for-free</link><guid isPermaLink="true">https://codelounge.dev/the-best-20-places-to-learn-how-to-code-for-free</guid><category><![CDATA[General Programming]]></category><category><![CDATA[100DaysOfCode]]></category><category><![CDATA[General Advice]]></category><category><![CDATA[#codenewbies]]></category><dc:creator><![CDATA[CodeLounge]]></dc:creator><pubDate>Thu, 01 Apr 2021 05:49:27 GMT</pubDate><enclosure url="https://cdn.hashnode.com/res/hashnode/image/upload/v1617256122708/XaVuHq0X7.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>There are a plethora of resources to learn how to code for free. However, the question is - which ones are worth using? As a result, this article shows you the best places to learn how to code for free. </p>
<h1 id="1-freecodecamphttpswwwfreecodecamporglearn">1. <a target="_blank" href="https://www.freecodecamp.org/learn">freeCodeCamp</a></h1>
<p>freeCodeCamp is one of the most well-known and popular platforms to learn how to code. There is 3000 hours worth of material! However, do not let the big number of hours - 3000 - scare you! You do not have to learn everything, and even if you want, you can do that over a long period of time.</p>
<p>freeCodeCamp offers the following paths and certifications:</p>
<ul>
<li>Responsive Web Design</li>
<li>JavaScript Algorithms and Data Structures</li>
<li>Front End Development</li>
<li>Data Visualization</li>
<li>APIs and Microservices</li>
<li>Quality Assurance</li>
<li>Scientific Computing with Python</li>
<li>Data Analysis with Python</li>
<li>Information Security</li>
<li>Machine Learning with Python</li>
</ul>
<p>Besides that, it offers a section dedicated to coding interview preparations. As a result, freeCodeCamp is a great resource to learn programming for free through practice. That means you learn by doing, which is one of the most efficient ways to learn how to code.</p>
<h1 id="2-the-odin-projecthttpswwwtheodinprojectcom">2. <a target="_blank" href="https://www.theodinproject.com">The Odin Project</a></h1>
<p>The Odin Project is another excellent resource where you learn programming by doing. They offer a Full Stack curriculum that helps you start your journey in Web Development.</p>
<p>They teach technologies such as HTML, CSS, JavaScript, Git, SQL databases, Node.js, Ruby, Ruby on Rails. <strong>What paths do they offer?</strong> They provide the following paths:</p>
<ul>
<li><strong>Foundations</strong> - This is an introduction to the foundations of Web Development. You learn how to set up your development environment, the Git basics, JavaScript basics and so on.</li>
<li><strong>Full Stack JavaScript</strong> - This path teaches you how to create web applications and sites from scratch using plain JavaScript, Node.js, CSS and HTML.</li>
<li><strong>Full Stack Ruby on Rails</strong> - It's similar to the other Full Stack path, except that it teaches you Ruby on Rails rather than Node.js</li>
</ul>
<p>The Odin Project is a great resource, and <strong>the best thing about it, is that you can join a supportive, dedicated community.</strong> They have their own Discord server where you can join and network with like-minded people.</p>
<h1 id="3-blogging-communities">3. Blogging communities</h1>
<p>These blogging communities are great because you can find a variety of subjects from a variety of writers.</p>
<p>Such a blogging community is Hashnode, where you can read on a variety of topics such as:</p>
<ul>
<li><a target="_blank" href="https://hashnode.com/n/javascript">JavaScript</a></li>
<li><a target="_blank" href="https://hashnode.com/n/python">Python</a></li>
<li><a target="_blank" href="https://hashnode.com/n/web-development">Web Development</a></li>
</ul>
<p>These topics are just some examples, but you can find a lot more on Hashnode. Besides that, there are authors of all levels. If you want to read advanced tutorials, you can do so. On the other hand, if you are a beginner and looking for likewise material, you can find that too.</p>
<p>However, there are other blogging communities such as:</p>
<ul>
<li>Medium</li>
<li>HackerNoon</li>
<li>freeCodeCamp blog</li>
</ul>
<h1 id="4-khan-academyhttpswwwkhanacademyorg">4. <a target="_blank" href="https://www.khanacademy.org/">Khan Academy</a></h1>
<p>The Khan Academy specifies on their home page that "you can learn anything". That's primarily true because they have an extensive curriculum where you can learn <em>Computing</em>
subjects and subjects adjacent to <em>Computing</em>.</p>
<p>However, focusing on the Computing subjects, you can use the Khan Academy to learn subjects such as:</p>
<ul>
<li>HTML and CSS</li>
<li>JavaScript</li>
<li>Algorithms</li>
<li>Data Structures</li>
<li>Cryptography</li>
<li>Advanced JavaScript such as drawing, animation, games, visualizations</li>
</ul>
<p><strong>The best thing about the Khan Academy</strong> is that anyone can use it to learn how to code. It does not matter your age; you can use it to learn how to program!</p>
<h1 id="5-sololearnhttpswwwsololearncom">5. <a target="_blank" href="https://www.sololearn.com">SoloLearn</a></h1>
<p>SoloLearn is another resource where you can learn to code for free. One thing that differentiates SoloLearn from other resources is that they have a mobile application as well. </p>
<p>So what? You might ask. That means you can learn to code anywhere and on almost any device. You are not tied to your laptop or any other machine. Each time you want to code, you can do so anywhere by pulling out your phone.</p>
<p>SoloLearn has a variety of courses to choose from, such as:</p>
<ul>
<li>Python</li>
<li>JavaScript</li>
<li>Java</li>
<li>CSS</li>
<li>SQL</li>
<li>React + Redux</li>
</ul>
<p>And many more. I invite you to visit their platform and pick the course you want to learn! <strong>The best thing about SoloLearn</strong> is the variety of courses they have.</p>
<h1 id="6-udacityhttpswwwudacitycom">6. <a target="_blank" href="https://www.udacity.com">Udacity</a></h1>
<p>Udacity is a well-known platform, and it provides 188 free courses. Their free courses are from fields such as:</p>
<ul>
<li>artificial intelligence</li>
<li>cloud computing</li>
<li>cybersecurity</li>
<li>data science</li>
<li>programming &amp; development</li>
</ul>
<p>Besides that, they have courses on career development, which is an essential topic as well. With Udacity, you can develop your technical skills, but the soft skills as well!</p>
<h1 id="7-youtube-channelshttpswwwyoutubecom">7. <a target="_blank" href="https://www.youtube.com">YouTube channels</a></h1>
<p>YouTube channels are a great way to learn how to program for free. There are a plethora of channels you can choose from. However, in this article, I will suggest you some searching terms for YouTube instead of specific channels. </p>
<p>The reason for suggesting searching terms rather than channels is because everyone has their preferences. If I like a channel, you might not. And vice-versa. Thus, by browsing searching terms, you can find the channels you want.</p>
<p>The topics you could search for are:</p>
<ul>
<li>Web Development</li>
<li>Web Design</li>
<li>Python</li>
<li>JavaScript</li>
<li>Java</li>
<li>Full Stack Tutorial</li>
</ul>
<p>Of course, these are just a few examples, but the sky is the limit. There is a ton of content for free! Make the most of it.</p>
<h1 id="8-codecademyhttpswwwcodecademycom">8. <a target="_blank" href="https://www.codecademy.com">Codecademy</a></h1>
<p>On Codecademy, you can choose between three areas:</p>
<ul>
<li><strong>Web Development</strong> - This path prepares you to build basic websites and interactive web apps using HTML, CSS and JavaScript.</li>
<li><strong>Programming and Computer Science</strong> - This path introduces you to the world of programming with Python.</li>
<li><strong>Data Science</strong> - It teaches you SQL and Python to build the skills you need to analyze data.</li>
</ul>
<p>Their free plan provides you with enough lesson. However, if you want access to everything, you can upgrade to the paid plan. <strong>The best thing about Codecademy is that they have a mobile app so you can practice coding on the go!</strong></p>
<h1 id="9-edabithttpsedabitcom">9. <a target="_blank" href="https://edabit.com">Edabit</a></h1>
<p>Edabit describes themselves as the Duolingo for learning how to code. They added gamification to make the process of learning more enjoyable. By solving challenges, you gain XP and unlock achievements.</p>
<p>You can learn programming languages such as JavaScript, Python, Java, Ruby and more. They also have two beginner tutorials that teach you coding with JavaScript or Python, depending on what you want to learn. Once you learn the basics, you can go to the <strong>Challenges</strong> and practice what you learnt! Edabit is a great resource.</p>
<h1 id="10-edxhttpswwwedxorglearncomputer-programming">10. <a target="_blank" href="https://www.edx.org/learn/computer-programming">EDX</a></h1>
<p>EDX is one of the best resources because you can learn programming from real college courses created by the world's leading universities, such as Harvard and MIT. And that's for free!</p>
<p>There is no barrier anymore. You do not have to go to the world's leading universities to take their excellent courses. You can do it online. Isn't that great?</p>
<p>On EDX, you can learn essential coding skills needed for frontend and/or backend web development, machine learning, IOS, Android, and much more. They have a great collection of courses taught by professionals, and I highly recommend it!</p>
<h1 id="11-courserahttpswwwcourseraorgsearchtopiccomputer20scienceandindexprodallproductstermoptimizationandqueryfree">11. <a target="_blank" href="https://www.coursera.org/search?topic=Computer%20Science&amp;index=prod_all_products_term_optimization&amp;query=free">Coursera</a></h1>
<p>Like EDX, Coursera hosts courses from top universities like Yale, Michigan, Stanford, and leading companies like Google and IBM.</p>
<p>They have courses on web development, Java, C, SQL, R and many more. They have 123 courses in total. <strong>The best thing about Coursera is that they provide you with courses from leading universities, companies and professionals!</strong></p>
<h1 id="12-githubs-labhttpslabgithubcom">12. <a target="_blank" href="https://lab.github.com/">GitHub's Lab</a></h1>
<p>GitHub's lab is one of my favourite resources because they have lots of resources, and they are varied as well. First and foremost, you can learn essential skills: version control with Git.</p>
<p>Working as a developer means that you work with a version control system as well. It does not matter whether that's GitHub, GitLab, BitBucket or any other system. These version control systems allow teams to track changes. Thus, on the GitHub's lab websites, you can learn about VCS by using GitHub.</p>
<p>Besides learning about VCS, you can learn about DevOps, language and tools such as:</p>
<ul>
<li>CircleCI, Travis CI</li>
<li>HTML</li>
<li>Node with Express</li>
<li>Python</li>
<li>Ruby</li>
</ul>
<p>These are just some examples from their website, but you can learn more tools and technologies. <strong>The best thing about this resource is the variety of tutorials!</strong></p>
<h1 id="13-scotchhttpsscotchio">13. <a target="_blank" href="https://scotch.io">Scotch</a></h1>
<p>On their homepage, they have the following description - <em>fun and practical web development tutorials</em>. That means you can learn about web development topics such as:</p>
<ul>
<li>Vue</li>
<li>React</li>
<li>CSS</li>
<li>JavaScript</li>
<li>Node</li>
<li>Python</li>
</ul>
<p>And many more. Besides that, Scotch has three free courses that teach you Vanilla JavaScript, Vue and React from scratch. Scotch is a great resource to learn about a wide variety of topics!</p>
<h1 id="14-mithttpsocwmiteducoursesintro-programming">14. <a target="_blank" href="https://ocw.mit.edu/courses/intro-programming/">MIT</a></h1>
<p>Why bother to join the Massachusetts Institute of Technology (MIT) University when you can take their courses online? MIT offers great introductory courses to programming. Their courses are split into three categories:</p>
<ul>
<li><strong>General Introductions to Programming</strong> - These courses introduce you to the principles of computer science. It also helps you begin to develop programming skills. It uses the Python programming language.</li>
<li><strong>Language-Specific Courses</strong> - Introductions to programming with other programming languages than Python.</li>
<li><strong>Follow-up Courses</strong> - More advanced courses.</li>
</ul>
<p><strong>The best thing about MIT is that the resources are top quality!</strong> You are taught by MIT University professors.</p>
<h1 id="15-sitepointhttpswwwsitepointcomblog">15. <a target="_blank" href="https://www.sitepoint.com/blog/">SitePoint</a></h1>
<p>The SitePoint blog covers a wide range of topics. Even though they have paid courses, they have a lot of free resources as well!</p>
<p>You can find information and resources about topics such as:</p>
<ul>
<li>HTML and CSS</li>
<li>JavaScript</li>
<li>Design &amp; UX</li>
<li>WordPress</li>
<li>PHP</li>
</ul>
<p>If you want access to even more resources, you can pay a monthly fee. After that, you'll have access to all their resources - articles, books and video courses.</p>
<h1 id="16-css-trickshttpscss-trickscom">16. <a target="_blank" href="https://css-tricks.com/">CSS-Tricks</a></h1>
<p>Even though it has CSS in its name and is one of the most popular CSS resources, CSS-Tricks covers other areas! Their website description is as follows - <em>Daily articles about CSS, HTML, JavaScript, and all things related to web design and development.</em></p>
<p>Thus, you can learn about HTML, CSS, JavaScript, web development and web design concepts. Additionally, it has a newsletter that curates the best news around web development.</p>
<h1 id="17-html-doghttpswwwhtmldogcom">17. <a target="_blank" href="https://www.htmldog.com">HTML Dog</a></h1>
<p>The name "HTML Dog" is a bit misleading because you can learn about CSS and JavaScript too. That means you can learn about the three pillars of Web Development.</p>
<p>There are nine tutorials, three tutorials for each language. HTML, CSS and JavaScript tutorials are split into three levels:</p>
<ul>
<li>Beginner - Step-by-step guides taking you from 0.</li>
<li>Intermediate - It teaches you more concepts, crossing the basic level.</li>
<li>Advanced - It explores the depths of each language.</li>
</ul>
<p>If you want to learn Web Development, HTML Dog is a great resource! <strong>The best thing about it is that it has a reference page.</strong> That is, whenever you forget a concept, you can go back to the webpage and remind yourself about it.</p>
<h1 id="18-coderbytehttpscoderbytecom">18. <a target="_blank" href="https://coderbyte.com">CoderByte</a></h1>
<p>CoderByte is a website for coding challenges and technical interview preparation. In software development, practice is essential. Coding is about building stuff rather than memorizing concepts.</p>
<p>As a result, CoderByte is a great resource to practice what you learned using the other free resources. You can find:</p>
<ul>
<li>Data Structures and Algorithms coding problems</li>
<li>Interview preparation resources</li>
<li>JavaScript and Python material</li>
</ul>
<p>Challenge your knowledge with CoderByte.</p>
<h1 id="19-codewarshttpswwwcodewarscom">19. <a target="_blank" href="https://www.codewars.com">Codewars</a></h1>
<p>Similar to CoderByte, Codewars allows you to practice programming concepts through programming exercises.</p>
<p>There are a plethora of coding exercises to choose from. Moreover, you can choose between a multitude of programming languages to solve the problems. Codewars provides a fun, valuable and efficient way to practice your knowledge or learn new concepts1</p>
<h1 id="20-bentohttpsbentoio">20. <a target="_blank" href="https://bento.io/">Bento</a></h1>
<p>Bento is a platform where you can choose between 100+ web development topics. The best part of it? They are free!</p>
<p>Some of the topics you can choose from are HTML, CSS, JavaScript, Python and SQL. These are just a few topics, but you can learn more tools and technologies. They also have paths such as:</p>
<ul>
<li>Web Development Fundamentals</li>
<li>Front-Ent &amp; BackendBackend Tracks</li>
<li>Databases</li>
</ul>
<p><strong>The best thing about it is that it has a page with trending articles from the development community.</strong> Thus, you can find great articles that are outside Bento.</p>
<h1 id="conclusion">Conclusion</h1>
<p>These are the best places to learn coding for free I could find on the internet. Some of them help you learn concepts, while others allow you to practice what you learnt. I advise you to use them together, rather than picking one.</p>
<p>If you know more great resources, feel free to drop them in the comments!</p>
]]></content:encoded></item><item><title><![CDATA[Getting Started With Open-Source: How To Contribute]]></title><description><![CDATA[Article written for Asayer and published on their blog originally.


Contributing to open-source projects is a great way to improve your programming skills and contribute to the community. Also, it's important to note that contributing to open-source...]]></description><link>https://codelounge.dev/getting-started-with-open-source-how-to-contribute-1</link><guid isPermaLink="true">https://codelounge.dev/getting-started-with-open-source-how-to-contribute-1</guid><category><![CDATA[General Programming]]></category><category><![CDATA[General Advice]]></category><category><![CDATA[Open Source]]></category><dc:creator><![CDATA[CodeLounge]]></dc:creator><pubDate>Wed, 31 Mar 2021 15:26:25 GMT</pubDate><enclosure url="https://cdn.hashnode.com/res/hashnode/image/upload/v1617204364548/x_lOaKCBh.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<hr />
<blockquote>
<p>Article written for Asayer and published on their <a target="_blank" href="https://blog.asayer.io/getting-started-with-open-source-how-to-contribute">blog originally</a>.</p>
</blockquote>
<hr />
<p>Contributing to open-source projects is a great way to improve your programming skills and contribute to the community. Also, it's important to note that contributing to open-source projects is not all about coding. You can contribute in other ways. For example:</p>
<ul>
<li>organise code</li>
<li>write or improve the documentation</li>
<li>design stuff</li>
<li>review code</li>
</ul>
<p>Before going further, I advise you to read the code of conduct and the contribution guidelines. Please read them carefully before you start contributing because it explains what is expected from you. It also describes the workflow required to make contributions. The Open-Source guide has a great article on this subject - <a target="_blank" href="https://opensource.guide/code-of-conduct/">Your Code of Conduct</a>.</p>
<p>Are you ready to make your first contributions? Let's do it!</p>
<h1 id="1-find-a-project">1. Find a project</h1>
<p>Finding a project to contribute to is a difficult task. I advise you to start small and pick a small project at first. Why? Things move faster in a small project, and it's more likely to get your first contribution. But if you feel adventurous, you can start with a bigger project!</p>
<p>Moving further, there are a handful of useful websites which you can use to find projects and issues suited for beginners. Here is a non-exhaustive list:</p>
<ul>
<li>goodfirstissues.com - This website is great because it only contains issues that are suited for first time contributors; that is, for beginners. You can filter projects by programming language and repository.</li>
<li><a target="_blank" href="https://goodfirstissue.dev">goodfirstissue.dev</a> - More or less, the same thing as the above website. Good First Issue curates easy pickings from popular open-source projects and helps you make your first contribution to open-source.</li>
<li>up-for-grabs.net - This website is a list of projects which have curated tasks specifically for new contributors.</li>
<li>github.com/explore - This is the explore page from Github itself. You can find lots of projects, but you have to search for issues suited for beginners manually.</li>
</ul>
<p>These websites should be more than enough to find a project. If not, you pick a tool that you use daily and contribute to that if it's open-source.</p>
<h1 id="2-basic-git-workflow">2. Basic Git workflow</h1>
<p>This article assumes basic knowledge of Git. The Git workflow you will be using is as follows:</p>
<ol>
<li>Fork the repository to your GitHub account.</li>
<li>Clone the project on your machine.</li>
<li>Create a branch before making changes.</li>
<li>Make your changes.</li>
<li>Commit and push your changes.</li>
<li>Open a pull request.</li>
</ol>
<p>The above workflow is the most basic one, and it's enough to contribute to open source projects. It's important to note that there are other variants, as well. However, you will use this one in the tutorial.</p>
<h1 id="3-fork-the-project">3. Fork the project</h1>
<p>Let's assume you found the perfect project to contribute. I will use the <a target="_blank" href="https://github.com/catalinpit/OSS-Contribution">OSS-Contribution</a> repository I created a while ago for this tutorial.</p>
<blockquote>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1616089776958/Ex7jwqAVN.png" alt="Screenshot 2021-03-18 at 19.48.38.png" />
Figure 1</p>
</blockquote>
<p>Go to the repository page, and click on the <code>Fork</code> button, as shown in figure 1 above! </p>
<p><strong>Why fork it first and not clone it directly?</strong> When you fork a project, you make a copy of it in your account. As a result, you can work on it without affecting the original repository. Forking creates a separate copy, whereas cloning downloads the project on your machine. Also, you cannot make changes to the repository if you only clone it. Only authorised people can make changes. By forking the project, you can make changes and submit pull requests.</p>
<p>After the forking is complete, it will redirect you to your copy of the project. Now it's time to move onto the next step.</p>
<h1 id="4-clone-the-project">4. Clone the project</h1>
<p>Now clone the project from your account. Go to the repository page to find the link.</p>
<blockquote>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1616090573604/vGqYf2tA8.png" alt="fs.png" />
Figure 2</p>
</blockquote>
<p>To find the forked repository URL, click on the green button saying <code>Code</code> and copy the URL as shown in figure 2.</p>
<p>After copying the link, go to your terminal and run the following command <em>(replace the URL with yours)</em>:</p>
<pre><code>git <span class="hljs-keyword">clone</span> https:<span class="hljs-comment">//github.com/catalinstech/OSS-Contribution.git</span>
</code></pre><p>Wait for the repository to download and then open it in your favourite code editor.</p>
<h1 id="5-create-a-branch">5. Create a branch</h1>
<p>Before making any changes to the codebase, it's important to create a new branch. Branches allow people to work on the project without getting into conflict with each other. Also, each branch is independent of others, so your branch's changes are not visible in another branch (unless they are merged).</p>
<p>In the simplest words, your branch holds the changes you make to the project. Also, read the branch naming convention of each project. All projects specify how you should name your branches. Some examples are:</p>
<ul>
<li><code>your_name/issue_fix</code> - E.g. catalinpit/add-name-768</li>
<li><code>issue_number-issue</code> - E.g. ET182-Fix-broken-navbar</li>
</ul>
<p>Moving on, you can create a new branch and switch to it as follows:</p>
<pre><code>git branch <span class="hljs-tag">&lt;<span class="hljs-name">your_branch_name</span>&gt;</span>
git checkout <span class="hljs-tag">&lt;<span class="hljs-name">your_branch_name</span>&gt;</span>
</code></pre><p>Alternatively, you can do the same thing in one command as follows:</p>
<pre><code>git checkout -b <span class="hljs-tag">&lt;<span class="hljs-name">your_branch_name</span>&gt;</span>
</code></pre><p>Now that you created a new branch, you are ready to make changes! Move onto the next section.</p>
<h1 id="6-make-changes">6. Make changes</h1>
<blockquote>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1616133977788/IX_7lmFcR.png" alt="download.png" />
Figure 3</p>
</blockquote>
<p>The next step is to make changes in the repository. I cannot advise you about making changes because it depends on each repository.</p>
<p>However, using my Github example repository, I added a new Twitter account in the <code>README</code> file. Now you need to commit and push your changes, which you will do in the next step.</p>
<h1 id="7-publish-your-changes">7. Publish your changes</h1>
<p>The first step is to add all your changes to the staging area. Basically, the <code>add</code> command includes your updates from a particular file in the next commit. It specifies what "to send to Github", in the simplest terms ever. </p>
<p>Run either of the following commands:</p>
<pre><code>git <span class="hljs-keyword">add</span> . 

// <span class="hljs-keyword">or</span>

git <span class="hljs-keyword">add</span> README.md (your file <span class="hljs-type">name</span> might differ)
</code></pre><p><code>git add .</code> adds all your changes to the staging area. For instance, if you made changes in 10 files, it adds all those files. On the other hand, you can handpick changes by specifying the file name, as in the second version above. It only includes the files you specify.</p>
<h4 id="commit-your-changes">Commit your changes</h4>
<p>You included the updates in the staging area, but now you have to commit them as well. Committing files means saving your updates to the local repository. Think of it as saving a Word document after making changes.</p>
<pre><code>git <span class="hljs-keyword">commit</span> -m "Added my name to the README"
</code></pre><p>You can see the <code>git commit</code> command in action above. The `-m' flag stands for "message", and it allows you to summarise your changes. That means you should describe what you did in the project. Try to make the commit messages as concise and descriptive as possible. At the same time, it does not mean you should write a novel.</p>
<h4 id="push-your-changes">Push your changes</h4>
<p>The last step is to "push" the changes to the remote repository. Until you "push" your changes, they are only available in your local repository. That is, nobody can see them except yourself.</p>
<p>To push your changes, run the following command:</p>
<pre><code>git push -u origin &lt;your-branch-<span class="hljs-type">name</span>&gt;
</code></pre><p>You are almost done now! The next and last step is to create a Pull Request, which you'll see in the next chapter.</p>
<h1 id="8-open-a-pull-request">8. Open a pull request</h1>
<blockquote>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1616136305402/eYHDgIyNp.png" alt="download (1).png" />
Figure 4</p>
</blockquote>
<p>Suppose you followed all the steps from the seventh step - <code>7. Publish your changes</code> - you should get a link in your terminal to open a pull request. Figure 4 (above) illustrates what you should see in your terminal. </p>
<p>If you do not get the same output for some reason, you can go to the <code>repository URL &gt; Pull requests tab &gt; click on the Compare &amp; pull request</code>. See figure 5 below.</p>
<blockquote>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1616138181397/u8Xpx96Hx.png" alt="Screenshot 2021-03-19 at 09.15.12.png" />
Figure 5</p>
</blockquote>
<p>Whatever option you choose, a new window should open where you can create the pull request. Figure 6 illustrates that!</p>
<p><strong>Be careful, though!</strong> Before submitting the pull request, make sure you read the contribution guidelines. At the minimum, add a descriptive title and description!</p>
<blockquote>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1616136411248/6yLfMlEdB.png" alt="Screenshot 2021-03-19 at 08.46.35.png" />
Figure 6</p>
</blockquote>
<p>Click on the green button saying <code>Create pull request</code>, and you are done! All you have to do is to wait for PR comments. Well done!</p>
<h4 id="why-do-you-need-a-pr">Why do you need a PR?</h4>
<p>By opening a pull request, other people can see the changes you've made to the codebase. Additionally, it allows other members to do a code review, which in turn might help you improve your skills and code. Thus, you can get valuable feedback!</p>
<p>Also, some changes might not be approved for various reasons, such as:</p>
<ul>
<li>poor code quality</li>
<li>inefficient implementation
... and many others.</li>
</ul>
<p>By creating pull requests, you protect the codebase from unwanted additions. Without pull requests, everyone can merge whatever they want to the <code>main</code> branch. Thus, the code quality will suffer.</p>
<p>In conclusion, pull requests helps and allows developers to:</p>
<ul>
<li>maintain a high-quality codebase</li>
<li>avoid introducing <em>(too many)</em> bugs <em>(because it can happen with PRs as well)</em></li>
<li>get feedback on the code</li>
<li>improve their skills and code</li>
</ul>
<h1 id="conclusion">Conclusion</h1>
<p>Well done for learning the most basic Git workflow you can use to make OSS contributions. Also, well done for making your first open-source contribution if you followed the article!</p>
]]></content:encoded></item></channel></rss>