<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Lennox Charles</title>
    <description>The latest articles on DEV Community by Lennox Charles (@lennyaiko).</description>
    <link>https://dev.to/lennyaiko</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F449680%2Fba846ebb-4b59-4346-bc4c-67b4f7335804.png</url>
      <title>DEV Community: Lennox Charles</title>
      <link>https://dev.to/lennyaiko</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/lennyaiko"/>
    <language>en</language>
    <item>
      <title>5 Full-Stack JavaScript Frameworks 2024</title>
      <dc:creator>Lennox Charles</dc:creator>
      <pubDate>Tue, 05 Mar 2024 15:36:12 +0000</pubDate>
      <link>https://dev.to/lennyaiko/5-full-stack-javascript-frameworks-2024-4ep</link>
      <guid>https://dev.to/lennyaiko/5-full-stack-javascript-frameworks-2024-4ep</guid>
      <description>&lt;p&gt;The web has never been more amazing and robust than now. I am a big fan of the web, and I like to share whatever knowledge I gather about it. In this article, I will introduce you to a few full-stack JavaScript frameworks that you can start learning about from the many available ones, in no particular sequence.&lt;/p&gt;

&lt;p&gt;Let's begin!&lt;/p&gt;

&lt;h3&gt;
  
  
  Next.js
&lt;/h3&gt;

&lt;p&gt;Next.js is a React framework for building full-stack web applications. You use React Components to build user interfaces, and Next.js for additional features and optimizations.&lt;/p&gt;

&lt;p&gt;Under the hood, Next.js also abstracts and automatically configures tooling needed for React, like bundling, compiling, and more. This allows you to focus on building your application instead of spending time with configuration.&lt;/p&gt;

&lt;p&gt;Whether you're an individual developer or part of a larger team, Next.js can help you build interactive, dynamic, and fast React applications.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://nextjs.org/docs/getting-started/installation"&gt;Get started&lt;/a&gt;.&lt;/p&gt;

&lt;h3&gt;
  
  
  The Boring JavaScript Stack
&lt;/h3&gt;

&lt;p&gt;Whether you prefer the simplicity of Vue, the flexibility of React, or the efficiency of Svelte, The Boring JavaScript Stack accommodates your choice. With The Boring JavaScript Stack, the UI of your app is simply the components of your chosen UI framework.&lt;/p&gt;

&lt;p&gt;So if you enjoy writing React's JSX, you'd love The Boring JavaScript Stack, as that's the only thing you have to know about React - writing components. Same thing with Vue and Svelte.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://docs.sailscasts.com/boring-stack/getting-started"&gt;Get started&lt;/a&gt;.&lt;/p&gt;

&lt;h3&gt;
  
  
  Nuxt.js
&lt;/h3&gt;

&lt;p&gt;Nuxt is a framework designed to give you a strong architecture following official Vue guidelines. Incrementally adoptable, it can be used to create everything from static landing pages to complex enterprise ready web applications.&lt;/p&gt;

&lt;p&gt;Versatile by nature, it supports different targets (server, serverless or static) and server side rendering is switchable.&lt;/p&gt;

&lt;p&gt;Extendable with a strong module ecosystem, it makes it easy to connect your REST or GraphQL endpoints, favorite CMS, CSS frameworks and more. PWA and AMP support is only a module away from your Nuxt project.&lt;/p&gt;

&lt;p&gt;NuxtJS is the backbone of your Vue.js project, giving structure to build your project with confidence while being flexible.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://nuxtjs.ir/guide"&gt;Get started&lt;/a&gt;.&lt;/p&gt;

&lt;h3&gt;
  
  
  Sails.js
&lt;/h3&gt;

&lt;p&gt;Sails is, of course, a web framework. But take a step back. What does that mean? Sometimes, when we refer to the "web", we mean the "front-end web." We think of concepts like web standards, or HTML 5, or CSS 3; and frameworks like React, or Vue.js, or jQuery. Sails is not "that kind" of a web framework. Sails works great with React and Vue, but you would never use Sails instead of those libraries.&lt;/p&gt;

&lt;p&gt;On the other hand, sometimes when we talk about "web frameworks", we mean the "back-end web." This evokes concepts like REST, or HTTP, or WebSockets; and technologies like Java, or Ruby, or Node.js. A "back-end web" framework helps you do things like build APIs, serve HTML files, and handle hundreds of thousands of simultaneous users. Sails is "that kind" of web framework.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://sailsjs.com/get-started"&gt;Get started&lt;/a&gt;.&lt;/p&gt;

&lt;h3&gt;
  
  
  Nest.js
&lt;/h3&gt;

&lt;p&gt;Nest (NestJS) is a framework for building efficient, scalable Node.js server-side applications. It uses progressive JavaScript, is built with and fully supports TypeScript (yet still enables developers to code in pure JavaScript), and combines elements of OOP (Object-Oriented Programming), FP (Functional Programming), and FRP (Functional Reactive Programming).&lt;/p&gt;

&lt;p&gt;Under the hood, Nest makes use of robust HTTP server frameworks like Express (the default) and can optionally be configured to use Fastify as well!&lt;/p&gt;

&lt;p&gt;Nest provides a level of abstraction above these common Node.js frameworks (Express and Fastify), but also exposes their APIs directly to the developer. This gives developers the freedom to use the myriad of third-party modules that are available for the underlying platform.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://docs.nestjs.com/"&gt;Get started&lt;/a&gt;.&lt;/p&gt;

&lt;h3&gt;
  
  
  Conclusion
&lt;/h3&gt;

&lt;p&gt;As mentioned, these frameworks were listed in no particular order. Personally, I have 3 out of the 5 mentioned in this article, and they are commendable with their pros and cons.&lt;/p&gt;

&lt;p&gt;Do have fun with them, and feel free to connect with me about your learning progress.&lt;/p&gt;

</description>
      <category>fullstack</category>
      <category>webdev</category>
      <category>javascript</category>
      <category>frontend</category>
    </item>
    <item>
      <title>Quick and easy loading spinner without JavaScript!</title>
      <dc:creator>Lennox Charles</dc:creator>
      <pubDate>Mon, 04 Mar 2024 19:47:32 +0000</pubDate>
      <link>https://dev.to/lennyaiko/quick-and-easy-loading-spinner-without-javascript-3l51</link>
      <guid>https://dev.to/lennyaiko/quick-and-easy-loading-spinner-without-javascript-3l51</guid>
      <description>&lt;p&gt;In this article, you will learn how to set up a quick and easy loading spinner using just Tailwind CSS. Stick around till the end to get the extra feature.&lt;/p&gt;

&lt;h3&gt;
  
  
  Why use Tailwind CSS, not JavaScript?
&lt;/h3&gt;

&lt;p&gt;The reason for using Tailwind CSS is to reduce the amount of JavaScript being shipped with the framework you are making use of. The less JavaScript you have, the more lightweight your web application becomes.&lt;/p&gt;

&lt;h3&gt;
  
  
  The Spinner
&lt;/h3&gt;

&lt;p&gt;Working with Tailwind CSS helps you ship faster, and you don't need to spend so much time styling or organising your CSS files.&lt;/p&gt;

&lt;p&gt;Let's get started.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;&amp;lt;div class="flex items-center justify-center h-[50vh]"&amp;gt;
  &amp;lt;div class="animate-spin rounded-full h-16 w-16 border-t-2 border-blue-500"&amp;gt;&amp;lt;/div&amp;gt;
&amp;lt;/div&amp;gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;That's all you need to get a simple loading spinner in your web application.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;&lt;code&gt;animate-spin&lt;/code&gt;: This class adds a rotating animation to the element.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;code&gt;rounded-full&lt;/code&gt;: This class makes the element a perfect circle by rounding its corners.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;code&gt;h-16 w-16&lt;/code&gt;: These classes set the height and width of the spinner. You can adjust the values based on your design.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;code&gt;h-[50vh]&lt;/code&gt;: This class sets a responsive height for all screens.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;code&gt;border-t-2 border-blue-500&lt;/code&gt;: These classes add a border to the top of the spinner, creating the appearance of a spinner with a specific color (blue-500). You can customize the color by choosing a different Tailwind CSS color class.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Make it Reusable
&lt;/h3&gt;

&lt;p&gt;An extra is to show you how to make it reusable in Vue and React.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Vue&lt;/strong&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;&amp;lt;template&amp;gt;
  &amp;lt;div class="flex items-center justify-center"&amp;gt;
    &amp;lt;div class="animate-spin rounded-full h-16 w-16 border-t-2 border-blue-500"&amp;gt;&amp;lt;/div&amp;gt;
  &amp;lt;/div&amp;gt;
&amp;lt;/template&amp;gt;

&amp;lt;script&amp;gt;
export default {
  name: 'Spinner'
};
&amp;lt;/script&amp;gt;

&amp;lt;style scoped&amp;gt;
/* Add any scoped styles if needed */
&amp;lt;/style&amp;gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;React&lt;/strong&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;import React from 'react';

const Spinner = () =&amp;gt; {
  return (
    &amp;lt;div className="flex items-center justify-center"&amp;gt;
      &amp;lt;div className="animate-spin rounded-full h-16 w-16 border-t-2 border-blue-500"&amp;gt;&amp;lt;/div&amp;gt;
    &amp;lt;/div&amp;gt;
  );
};

export default Spinner;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;You can conditionally render the loading spinners when updating a state or fetching data from an API.&lt;/p&gt;

&lt;h3&gt;
  
  
  Resources
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;&lt;a href="https://tailwindcss.com/docs/installation"&gt;Get started with Tailwind CSS.&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;a href="https://react.dev/learn"&gt;Get started with React.&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;a href="https://vuejs.org/guide/introduction.html"&gt;Get started with Vue.&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

</description>
      <category>tailwindcss</category>
      <category>javascript</category>
      <category>react</category>
      <category>vue</category>
    </item>
    <item>
      <title>Estimate the read time of an article without any library in JavaScript.</title>
      <dc:creator>Lennox Charles</dc:creator>
      <pubDate>Fri, 01 Mar 2024 20:56:19 +0000</pubDate>
      <link>https://dev.to/lennyaiko/estimate-the-read-time-of-an-article-without-any-library-in-javascript-2k4e</link>
      <guid>https://dev.to/lennyaiko/estimate-the-read-time-of-an-article-without-any-library-in-javascript-2k4e</guid>
      <description>&lt;p&gt;In this article, we'll embark on a journey to craft a JavaScript function to help us estimate the read time of an article. You will dabble with a little bit of regex to help you strip your content clean for proper estimation. Keep in mind that since this is pure JavaScript, it works across the stack (front-end and back-end).&lt;/p&gt;

&lt;p&gt;Let's get started.&lt;/p&gt;

&lt;h2&gt;
  
  
  Strip HTML Tags
&lt;/h2&gt;

&lt;p&gt;If there are HTML tags present in your content, you will need to strip the content to make the estimation more accurate.&lt;/p&gt;

&lt;p&gt;To do that, we have to do some regex:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;const htmlTagRegExp = /&amp;lt;\/?[^&amp;gt;]+(&amp;gt;|$)/g
const textWithoutHtml = text.replace(htmlTagRegExp, '')
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;htmlTagRegExp&lt;/strong&gt;: The regex function catches any HTML tag syntax.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;textWithoutHtml&lt;/strong&gt;: The &lt;code&gt;.replace&lt;/code&gt; property replaces the HTML tag syntax caught by the regex with a blank space.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;With that, we achieved the first phase of the estimation.&lt;/p&gt;

&lt;h2&gt;
  
  
  Match all words
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;const wordMatchRegExp = /[^\s]+/g
const words = textWithoutHtml.matchAll(wordMatchRegExp)
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;wordMatchRegExp&lt;/strong&gt;: This regex function is used to match all non-whitespace characters. It's designed to match individual words in a text.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;words&lt;/strong&gt;: The matchAll method is used to find all matches of the regular expression in the given textWithoutHtml. It returns an iterator containing all the matches.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Let's Estimate!
&lt;/h2&gt;

&lt;p&gt;To estimate the read time of the content, you will unpack words and get the length as the word count. Then you divide it by 200. Why? because 200 words per minute is the assumed average reading speed.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;const wordCount = [...words].length
const readTime = Math.round(wordCount / 200)
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;With that, you have gotten the estimated read time of your content.&lt;/p&gt;

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

&lt;p&gt;You can always set this up as a reusable function in your project and make use of it without installing any additional packages.&lt;/p&gt;

&lt;p&gt;See you on the next one.&lt;/p&gt;

</description>
      <category>javascript</category>
      <category>webdev</category>
      <category>tutorial</category>
      <category>beginners</category>
    </item>
    <item>
      <title>"API Thinking" - Know your audience category</title>
      <dc:creator>Lennox Charles</dc:creator>
      <pubDate>Sat, 25 Mar 2023 17:47:27 +0000</pubDate>
      <link>https://dev.to/lennyaiko/api-thinking-know-your-audience-category-3o62</link>
      <guid>https://dev.to/lennyaiko/api-thinking-know-your-audience-category-3o62</guid>
      <description>&lt;p&gt;When building an API (Application Programmable Interface), no matter what stage you are in the process, it is always important to correctly identify your target audience. This step is essential when developing an API, why?, it will enable you to know how to market your API correctly and to the right people.&lt;/p&gt;

&lt;p&gt;However, there are lots of benefits when you find the right audience for your API. I'll be concentrating on the three main categories into which your audience might be segmented in this article.&lt;/p&gt;

&lt;p&gt;PS: In subsequent posts, I will talk about knowing your target audience, I would recommend you stick around, just a piece of friendly advice ;-)&lt;/p&gt;

&lt;p&gt;Now let the fun begin!&lt;/p&gt;

&lt;h2&gt;
  
  
  3 Categories of audiences
&lt;/h2&gt;

&lt;h3&gt;
  
  
  Private APIs
&lt;/h3&gt;

&lt;p&gt;You might have heard of this before-but if not-No, this is not an API running on your local desktop. This is an API that exposes part of an organization's backend data for developers working in the same organization. Gotten an idea?&lt;/p&gt;

&lt;p&gt;Private APIs can have usage limits and can only be accessed by authorized users. A simple scenario where private APIs are frequently used is for businesses to grant authorized employees and partners access to their internal data and systems.&lt;/p&gt;

&lt;p&gt;One key benefit of private APIs is they can significantly reduce development time and resources.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;FOOD FOR THOUGHT&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;The purpose of a private API is to make it possible for internal developers who are creating new apps to utilize existing systems like the backend already being used by the organization. You need to ensure that the program satisfies both the organization's short-term project objectives.&lt;/p&gt;

&lt;h3&gt;
  
  
  Public APIs
&lt;/h3&gt;

&lt;p&gt;Now, this is the famous one, public APIs are designed to be easily accessible by a wider population of web and mobile developers. It can literally be used both by developers inside and outside the organization.&lt;/p&gt;

&lt;p&gt;This category of APIs helps smaller organizations create organic interests in their core business values. Although it can generate revenue if usage is substantial, it can also be used as a marketing channel for smaller businesses.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;FOOD FOR THOUGHT&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;A public API's success will depend on its capacity to draw outside developers and assist them in building genuinely useful new applications that users actually desire to use. The primary objective should be to promote API usage, both in terms of quantity and quality.&lt;/p&gt;

&lt;p&gt;Lastly,&lt;/p&gt;

&lt;h3&gt;
  
  
  Partner APIs
&lt;/h3&gt;

&lt;p&gt;These APIs are typically used to support apps created by programmers working for a company that already has a working relationship with the API developer.&lt;/p&gt;

&lt;p&gt;Sounds similar to private APIs right? Let me clarify that for you:&lt;/p&gt;

&lt;p&gt;Partner APIs are private APIs that have been made available for authorized partners only. It may have special terms and conditions concerning its usage. &lt;/p&gt;

&lt;p&gt;Now you see the difference? of course, you do.&lt;/p&gt;

&lt;p&gt;To implement a partnership API, the API developer will need to have knowledge and direct access to the client developer application.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;FOOD FOR THOUGHT&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Be as it may, the API developer or designer will need to have access to the developer application, but they lack direct influence or authority over the developer.&lt;/p&gt;

&lt;p&gt;Regardless, it will be good to know how the API will be used and by whom.&lt;/p&gt;

&lt;h2&gt;
  
  
  BONUS: Where to find APIs you can use
&lt;/h2&gt;

&lt;p&gt;As an added bonus to this essay, I'll show you some places where you can find APIs to use or recommend.&lt;/p&gt;

&lt;p&gt;DISCLAIMER: I have no affiliation whatsoever to these sites, just sharing a resource.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;RapidAPI.com:&lt;/strong&gt; The largest API marketplace in the world, RapidAPI, with more than 10,000 APIs and one million active developers. On this website, cutting-edge APIs are categorized according to the industries in which they are used.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;ProgrammableWeb:&lt;/strong&gt; ProgrammableWeb is a strong API repository with the largest, hand-curated API directory in the world, with an estimated 17,000 APIs. This website, which was created by Mulesoft, also offers a ton of news, press releases, tutorials, reviews, and articles about APIs.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;API List:&lt;/strong&gt; Since its 2017 launch, API List has become one of the web's most trustworthy sites for API information. There are several APIs available on this site, including more than 800 free APIs.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;API For That:&lt;/strong&gt; API For That is another top-notch website where you can get a hand-curated directory. The portal features over 400 API profiles in over 20 industrial areas. Additionally, each API in this repository comes with a description, some basic documentation, and a link to the webpage of the provider.&lt;/p&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;I could give a long list but you could easily find these resources on google, or whatever search engine you use.&lt;/p&gt;

&lt;h2&gt;
  
  
  Cessation
&lt;/h2&gt;

&lt;p&gt;Knowing the category your API falls in will determine how you search for your target audience. These categories only help to streamline your audience research.&lt;/p&gt;

&lt;p&gt;That's a wrap! Thanks for taking out time to read this post. See you in more subsequent posts. Feel free to use the comment session if you have any thoughts or corrections.&lt;/p&gt;

</description>
    </item>
    <item>
      <title>Getting started as an API developer</title>
      <dc:creator>Lennox Charles</dc:creator>
      <pubDate>Wed, 22 Mar 2023 09:57:57 +0000</pubDate>
      <link>https://dev.to/lennyaiko/getting-started-as-an-api-developer-56hh</link>
      <guid>https://dev.to/lennyaiko/getting-started-as-an-api-developer-56hh</guid>
      <description>&lt;p&gt;As we delve deeper into the technological era, we discover more possibilities. This explains the rise of AI and so many other trending technologies and frameworks.&lt;/p&gt;

&lt;p&gt;Companies are now looking for technologies to increase their productivity and profit margins. Most of that challenge is solved with APIs (Application Programmable Interfaces). Having API skills allows you to facilitate interaction between various servers and applications.&lt;/p&gt;

&lt;p&gt;For that to be possible, you need to embark on the journey of acquiring API-related skills and launch a career in API development. In this article, you will see what skills you need to get started. Drumrolls!&lt;/p&gt;

&lt;h2&gt;
  
  
  API development skills?
&lt;/h2&gt;

&lt;p&gt;Before getting to the nitty gritty, let's clarify some basic knowledge. An API serves as a messenger between two communicating servers or applications. It takes a request from the sender and sends it to the receiver; after processing the request, the receiver sends a response back to the server.&lt;/p&gt;

&lt;p&gt;Having API development skills will enable you to develop these "messengers"—an application or piece of software—that can perform that task.&lt;/p&gt;

&lt;p&gt;Slightly confused? Here's a basic example: You can connect your phone to a smartwatch to receive calls and read messages. An API is what makes that possible. It helps connect applications together to exchange information and perform any pre-defined task.&lt;/p&gt;

&lt;p&gt;Now that's out of the way, let's get to see some skills.&lt;/p&gt;

&lt;h2&gt;
  
  
  5 API development skills
&lt;/h2&gt;

&lt;p&gt;Keep in mind that these are not all the skills required, this is just enough to get started. These skillsets are:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;&lt;p&gt;Language proficiency in coding&lt;br&gt;
It is advisable for an API developer to have coding skills in a variety of languages. This makes sure you are using the appropriate language for the project you are working on. By all means, feel no pressure; it takes a lot of time to get a proper grasp of one language.&lt;br&gt;
&lt;strong&gt;Protip&lt;/strong&gt;: Learning the foundations of one language will make it easier to learn others.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Designing an API&lt;br&gt;
Knowing how to design an API is important because the better the design, the more enjoyable the experience of making use of it will be.&lt;br&gt;
&lt;strong&gt;Protip&lt;/strong&gt;: The better your API design, the more features are possible.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Platform Independence&lt;br&gt;
This skill allows you to build an application that works on diverse platforms with little or no maintenance.&lt;br&gt;
&lt;strong&gt;Protip&lt;/strong&gt;: Building platform-independent applications helps you narrow your focus, thereby improving productivity.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Knowledge of service-oriented architecture (SOA)&lt;br&gt;
It is all about being able to reuse your components when developing an API and being able to identify when an existing API has the functionality they need in their new API.&lt;br&gt;
&lt;strong&gt;Protip&lt;/strong&gt;: Reusing components speeds up the development time of new features or versions.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Fluency in communication&lt;br&gt;
Being able to document how your API works is important to ensure understanding for the users. Of course, to avoid answering a bunch of questions you might probably lose track of the answers.&lt;br&gt;
&lt;strong&gt;Protip&lt;/strong&gt;: Documentation helps present a clear and concise understanding of the API operations to the users.&lt;/p&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;h2&gt;
  
  
  Bonus: Simple tools you need to know
&lt;/h2&gt;

&lt;ol&gt;
&lt;li&gt;Swagger: an easy-to-use tool that helps you auto-document your API and provide a live interaction.&lt;/li&gt;
&lt;li&gt;Redoc: similar to swagger, but no live interaction.&lt;/li&gt;
&lt;li&gt;Databases: helps you store the data sent to your API. There are different types you can make use of, e.g MySQL, Postgres, MongoDB, etc.&lt;/li&gt;
&lt;li&gt;Postman: makes it easy to test your API.&lt;/li&gt;
&lt;/ol&gt;

&lt;h2&gt;
  
  
  Cessation
&lt;/h2&gt;

&lt;p&gt;The journey is continuous; do not be afraid to try new things. Continuous improvement is always better than delayed perfection. However, having a good source of information or knowledge will certainly boost your progress.&lt;/p&gt;

</description>
      <category>api</category>
      <category>webdev</category>
      <category>beginners</category>
      <category>programming</category>
    </item>
    <item>
      <title>Know Your HTTP Verbs - HTTP verbs for beginners</title>
      <dc:creator>Lennox Charles</dc:creator>
      <pubDate>Thu, 16 Mar 2023 19:48:08 +0000</pubDate>
      <link>https://dev.to/lennyaiko/know-your-http-verbs-http-verbs-for-beginners-11d7</link>
      <guid>https://dev.to/lennyaiko/know-your-http-verbs-http-verbs-for-beginners-11d7</guid>
      <description>&lt;p&gt;It is quite inevitable to use the wrong HTTP verb when developing your API, especially as a beginner. I once faced the same contingency when I was at the beginning phase of developing APIs. I knew what each verb meant, but I ignorantly misused them.&lt;/p&gt;

&lt;p&gt;After several projects and tutorials, I realized that I was following the wrong approach. With more understanding, I was able to practice using the right HTTP verb for the right purpose. That is what I will be showing you in this post.&lt;/p&gt;

&lt;p&gt;Before we get started, I believe we should cover as much as possible. Let's get to know what HTTP verbs are and why you should use them correctly.&lt;/p&gt;

&lt;h2&gt;
  
  
  What are HTTP verbs?
&lt;/h2&gt;

&lt;p&gt;HTTP stands for "Hypertext Transfer Protocol," and it is considered by many—myself included—to be the life of the web. When it comes to transferring documents or making a request, HTTP is the backbone. In simple terms, it is a protocol responsible for transferring documents over the web.&lt;/p&gt;

&lt;p&gt;Easy right? Let me guess: you have probably never heard of protocols. If you have, I think you should go to the next heading, but if you haven't, "protocols" are a determined set of rules that govern the exchange of information across the web.&lt;/p&gt;

&lt;h2&gt;
  
  
  Why should I use the right HTTP verb?
&lt;/h2&gt;

&lt;p&gt;As a developer of any stack, it is important to get a hang of the tools you use and be effective with them. Therefore, if you are developing APIs, you need to know how HTTP works. It gives your API an edge and ensures proper usage of third-party developers.&lt;/p&gt;

&lt;h2&gt;
  
  
  A little need to know
&lt;/h2&gt;

&lt;p&gt;It is important to understand two keywords when it comes to using HTTP verbs efficiently, and those are "safe" and "idempotent."&lt;/p&gt;

&lt;p&gt;Safe deals with read-only, which means you can make requests to an endpoint and not worry about any data being updated or destroyed.&lt;/p&gt;

&lt;p&gt;Idempotent, on the other hand, means you can make multiple requests to an endpoint without changing anything or getting a different result.&lt;/p&gt;

&lt;p&gt;Generally speaking, all safe methods are idempotent, but not all idempotent methods are safe. It's a bit of a conundrum if I must say so, but you are in the right place. You will get the idea as you read more.&lt;/p&gt;

&lt;h2&gt;
  
  
  Let's get right to it: HTTP Verbs
&lt;/h2&gt;

&lt;p&gt;Additional knowledge is that—after all, you are reading this to learn—HTTP verbs give the server instructions on what to do with the data sent through the URL. Now, let's talk about a few briefly.&lt;/p&gt;

&lt;h3&gt;
  
  
  GET
&lt;/h3&gt;

&lt;p&gt;You should use get only when you wish to read data, not store or update. Among others, the GET is the simplest verb. Conclusively, now that we know GET is only used for reading and the same data is always returned, we can say that they are safe and idempotent.&lt;/p&gt;

&lt;h3&gt;
  
  
  POST
&lt;/h3&gt;

&lt;p&gt;Whenever you try to make a POST request, everyone is expecting that you are trying to store something. That is trying to add a new resource to the database. The POST method is said to be neither safe nor idempotent because a new resource is being created, and making two requests to the same endpoint will yield different results.&lt;/p&gt;

&lt;h3&gt;
  
  
  PUT
&lt;/h3&gt;

&lt;p&gt;You may have come to the thought, "How then do I update?" This is where the PUT request comes in. It is often used in the context of updating resources. PUT can also be used to create new resources, but the client will have to define the ID. Trust me, it gets more complicated, so I won't advise that. What I recommend is to only use this verb when you want to update. It is not a safe operation because it makes changes on the server side, but guess what? It is an idempotent operation.&lt;/p&gt;

&lt;h3&gt;
  
  
  PATCH
&lt;/h3&gt;

&lt;p&gt;Here is where it gets interesting, PATCH is also used to update resources, but unlike PUT, it updates just the changed data and not the entire resource. It is neither safe nor idempotent. In the real world, PATCH is rarely used.&lt;/p&gt;

&lt;h3&gt;
  
  
  DELETE
&lt;/h3&gt;

&lt;p&gt;The way it sounds is how it operates. You can simply use DELETE to destroy redundant resources from the database. It is certainly not a safe operation, but some say it is idempotent and some say it is not.&lt;/p&gt;

&lt;h2&gt;
  
  
  Cessation
&lt;/h2&gt;

&lt;p&gt;Well, if you got to this extent, you have certainly gained one or two points. Another piece of advice I would like to give is that using the right HTTP verbs will make your API more fault-tolerant. Your API will also be more methodical in its operations.&lt;/p&gt;

&lt;p&gt;Here's a pro tip: the GET operation should never be used for creating or updating.&lt;/p&gt;

&lt;p&gt;That's a wrap! I'll see you again in subsequent posts.&lt;/p&gt;

</description>
      <category>api</category>
      <category>webdev</category>
      <category>productivity</category>
      <category>writing</category>
    </item>
    <item>
      <title>KNOW THE MATURITY OF YOUR RESTAPI</title>
      <dc:creator>Lennox Charles</dc:creator>
      <pubDate>Mon, 13 Mar 2023 17:46:11 +0000</pubDate>
      <link>https://dev.to/lennyaiko/know-the-maturity-of-your-restapi-n70</link>
      <guid>https://dev.to/lennyaiko/know-the-maturity-of-your-restapi-n70</guid>
      <description>&lt;p&gt;Recently, I was working on a FastAPI project; I got the idea from the "Real Python" website. While doing my studies on the project, I came across this model. So I thought I’d take a stab at my brainchild and talk about this.&lt;/p&gt;

&lt;p&gt;Leonardo Richardson proposed this model. It is used to grade or measure an API by its RESTful maturity.&lt;/p&gt;

&lt;p&gt;Leonardo analyzed hundreds of different web services and considered three factors before coming up with this new idea. &lt;/p&gt;

&lt;h2&gt;
  
  
  Factors
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;URI: Uniform Resource Identifier &lt;/li&gt;
&lt;li&gt;HTTP methods &lt;/li&gt;
&lt;li&gt;HATEOAS (Hypermedia)&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Categories
&lt;/h2&gt;

&lt;p&gt;Concluding, he divided these elements into 4 categories.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Level 0: The Swamp of POX - Single URI and Single Verb &lt;/li&gt;
&lt;li&gt;Level 1: Resources - Multiple URI-based resources and single verbs. &lt;/li&gt;
&lt;li&gt;Level 2: HTTP Verbs - Multiple URI-based resources and verbs. &lt;/li&gt;
&lt;li&gt;Level 3: Hypermedia Controls - HATEOAS&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Take into thought that a level higher is more RESTful than one lower. It is only when an API reaches level 4 that we consider it to be a RESTful API. Let’s delve into them, shall we?&lt;/p&gt;

&lt;h2&gt;
  
  
  Maturity Levels
&lt;/h2&gt;

&lt;h3&gt;
  
  
  Level 0: The Swamp of POX
&lt;/h3&gt;

&lt;p&gt;This level is also known as POX (Plain Old XML). HTTP is only used as a transport protocol for interaction between two systems. It does make use of the full HTTP features like HTTP methods and HTTP cache. To perform operations like get and post, it makes use of a single URI. Most of the time, the only HTTP method used is POST. In essence, this level makes use of SOAP web services in a REST style.&lt;/p&gt;

&lt;p&gt;For example, most SOAP Web Services use a single URI to identify an endpoint, and HTTP POST to transfer SOAP-based payloads, effectively ignoring the rest of the HTTP verbs.&lt;/p&gt;

&lt;p&gt;To get the data: &lt;a href="http://localhost:8080/posts"&gt;http://localhost:8080/posts&lt;/a&gt; &lt;/p&gt;

&lt;p&gt;To post the data: &lt;a href="http://localhost:8080/posts"&gt;http://localhost:8080/posts&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Similarly, XML-RPC-based services send data as Plain Old XML (POX).&lt;/p&gt;

&lt;h3&gt;
  
  
  Level 1: Resources
&lt;/h3&gt;

&lt;p&gt;Level 1 employs many URIs but makes use of a single verb, generally HTTP POST. It tackles difficulty by disintegrating a single service endpoint into multiple endpoints.&lt;/p&gt;

&lt;p&gt;For example: &lt;/p&gt;

&lt;p&gt;To get the list of posts: &lt;a href="http://localhost:8080/posts"&gt;http://localhost:8080/posts&lt;/a&gt; &lt;/p&gt;

&lt;p&gt;To get a specific post: &lt;a href="http://localhost:8080/posts/1"&gt;http://localhost:8080/posts/1&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Based on the multiple URIs available, makes this level better than the previous.&lt;/p&gt;

&lt;p&gt;Pro tip: There will be no required field in the DB, an empty body is to be sent to the API&lt;/p&gt;

&lt;h3&gt;
  
  
  Level 2: HTTP Verbs
&lt;/h3&gt;

&lt;p&gt;Level 2 generally hosts numerous URIs and supports several HTTP verbs. At this level, the state of resources can be easily manipulated over the network. i.e., it is now able to perform CRUD operations. For each request, the correct HTTP response code is provided.&lt;/p&gt;

&lt;p&gt;To get the list of posts: &lt;a href="http://localhost:8080/posts"&gt;http://localhost:8080/posts&lt;/a&gt; &lt;/p&gt;

&lt;p&gt;Response code: 200 OK&lt;/p&gt;

&lt;p&gt;This is the most popular use case of REST principles. It is mostly done automatically by different frameworks.&lt;/p&gt;

&lt;h3&gt;
  
  
  Level 3: Hypermedia Controls
&lt;/h3&gt;

&lt;p&gt;This is the peak level, it is quite the combination of level 2 and HATEOAS (Hypertext As The Engine Of Application State). It helps to describe possible interactions and how to carry them out. The links give client developers a hint as to what may be possible next.&lt;/p&gt;

&lt;p&gt;For example, when a request is sent, you get a response, a link and a URI.&lt;/p&gt;

&lt;h2&gt;
  
  
  CONCLUSION
&lt;/h2&gt;

&lt;p&gt;Be aware that any level you get to still makes your API a RESTful one, this is just to grade maturity.&lt;/p&gt;

&lt;p&gt;This is a good way to think about the elements of REST but it’s not a definition of levels of REST. Roy fielding made it clear that this is just a pre-condition of REST.&lt;/p&gt;

&lt;p&gt;What I find useful about this RMM is that it helps to understand the basic ideas of RESTful thinking. I see it as a tool to help learn about concepts, not something that should be used as an assessment mechanism.&lt;/p&gt;

&lt;h2&gt;
  
  
  SUMMARY
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;Level 1 tackles the question of handling complexity by using divide and conquer, breaking a large service endpoint down into multiple resources. &lt;/li&gt;
&lt;li&gt;Level 2 introduces a standard set of verbs so that we handle similar situations in the same way, removing unnecessary variation. &lt;/li&gt;
&lt;li&gt;Level 3 introduces discoverability, providing a way of making a protocol more self-documenting.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  BONUS
&lt;/h2&gt;

&lt;p&gt;Practical implementation: &lt;a href="https://github.com/lennyAiko/RMM-model-API.git"&gt;https://github.com/lennyAiko/RMM-model-API.git&lt;/a&gt;&lt;br&gt;
This project was coded using flask, swagger and OpenAPI Specification for REST APIs. &lt;/p&gt;

</description>
      <category>webdev</category>
      <category>programming</category>
      <category>python</category>
      <category>api</category>
    </item>
  </channel>
</rss>
