<?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[Ayooluwa's Blog]]></title><description><![CDATA[Read more about what I know in Web development. I write about my best practices, in Web Development, my experiences with the latest web technologies and projects I have worked on. Let's have fun!]]></description><link>https://blog.aayooluwa.com</link><image><url>https://cdn.hashnode.com/res/hashnode/image/upload/v1679614966961/kbgOsqKog.jpeg</url><title>Ayooluwa&apos;s Blog</title><link>https://blog.aayooluwa.com</link></image><generator>RSS for Node</generator><lastBuildDate>Sun, 26 Apr 2026 01:35:58 GMT</lastBuildDate><atom:link href="https://blog.aayooluwa.com/rss.xml" rel="self" type="application/rss+xml"/><language><![CDATA[en]]></language><ttl>60</ttl><item><title><![CDATA[What the Hell is Web 5.0?]]></title><description><![CDATA[Ever stumbled upon the term Web5 and wondered, "What on earth could that be?" Well, today's your lucky day, because we're about to unravel this mystery together!

Web5, in its essence, stands for the fifth iteration of the web, a revolutionary concep...]]></description><link>https://blog.aayooluwa.com/what-the-hell-is-web-50</link><guid isPermaLink="true">https://blog.aayooluwa.com/what-the-hell-is-web-50</guid><category><![CDATA[Web Development]]></category><category><![CDATA[software development]]></category><category><![CDATA[development]]></category><category><![CDATA[Web3]]></category><category><![CDATA[web 5.0 ]]></category><dc:creator><![CDATA[Coding Pastor]]></dc:creator><pubDate>Tue, 28 Nov 2023 05:00:11 GMT</pubDate><enclosure url="https://cdn.hashnode.com/res/hashnode/image/upload/v1701102191573/1e43e636-0dbb-40ba-9e73-45b05a3db580.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>Ever stumbled upon the term Web5 and wondered, "What on earth could that be?" Well, today's your lucky day, because we're about to unravel this mystery together!</p>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1701101676916/f2ec87f1-3ecc-491a-bb06-e38b35dbc100.gif" alt class="image--center mx-auto" /></p>
<p>Web5, in its essence, stands for the fifth iteration of the web, a revolutionary concept that's reshaping our online universe. But what's so special about it? What makes it the web of our dreams? Let’s decode this together!</p>
<h2 id="heading-the-webs-evolution-from-10-to-50"><strong>The Web's Evolution: From 1.0 to 5.0</strong></h2>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1701103017779/043e0919-2f7a-483d-8e67-4e1a803c72a7.gif" alt class="image--center mx-auto" /></p>
<h3 id="heading-the-dawn-of-the-web-web-10-the-read-only-era">The Dawn of the Web: Web 1.0, The "Read-Only" Era</h3>
<p>Imagine the early internet as a digital library, where you could browse and read but not interact. Web 1.0 was like the shy kid in class – full of information, but not much conversation. It was a static realm of online brochures and encyclopedias, where interaction was a one-way street.</p>
<h3 id="heading-the-rise-of-interactivity-web-20-the-social-web">The Rise of Interactivity: Web 2.0, The "Social" Web</h3>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1701104811972/de3e22f3-1315-416a-a3b1-c3398fccc3c0.gif" alt class="image--center mx-auto" /></p>
<p>Then came the teen years of the internet, Web 2.0, bustling with blogs, social networks, and cat videos. It was interactive, dynamic, and a bit nosy (think cookies and data tracking). This era brought us closer, but at a price – our data privacy.</p>
<h3 id="heading-web-30-and-beyond-semantic-web-and-decentralization">Web 3.0 and Beyond: Semantic Web and Decentralization</h3>
<p>Web 3.0 tried to smarten things up with the Semantic Web, making data more interconnected and meaningful. It was like the internet got a brain and started understanding us better. Then blockchain and cryptocurrencies hinted at a more decentralized future – a taste of digital freedom.</p>
<h3 id="heading-the-quantum-leap-web5-the-user-empowered-web">The Quantum Leap: Web5, The User-Empowered Web</h3>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1701105469300/b9bee6f0-74d1-4a72-bea2-4f555cb3f61d.jpeg" alt class="image--center mx-auto" /></p>
<p>Now, enter Web5, the latest prodigy in the web family. It’s not just a phase; it’s a revolution. Web5 brings the best of decentralization and user control to the forefront. It’s like having your own digital kingdom, where you rule your data and identity.</p>
<p>Basically, picture the web as a growing child. Web 1.0 was like a baby babbling (mostly read-only websites). Then Web 2.0 arrived, turning into a talkative teenager (hello, social media and user-generated content!). But as with all teens, there were privacy tantrums and data drama. Enter Web5, the mature, self-aware adult of the web family, putting you in charge.</p>
<h2 id="heading-the-champion-of-digital-autonomy"><strong>The Champion of Digital Autonomy</strong></h2>
<p>Web5 is like having a superpower – control over your digital identity. It’s not just an upgrade; it’s a total game-changer. Imagine a world where you’re not just a user, but the master of your digital universe.</p>
<h1 id="heading-the-technical-backbone-of-web-50">The Technical Backbone of Web 5.0</h1>
<h3 id="heading-decentralized-identity-the-core-of-web5"><strong>Decentralized Identity: The Core of Web5</strong></h3>
<p>Imagine if your online identity was as unique and untouchable as your DNA. In Web5, your digital ID is yours alone, stored not in the clutches of tech giants but in a decentralized manner. It is about having an uncrackable safe for your digital self.</p>
<h3 id="heading-dwns-your-personal-data-kingdoms"><strong>DWNs: Your Personal Data Kingdoms</strong></h3>
<p>Decentralized Web Nodes are similar to castles where your data rules. Here, your information is stored securely, away from the data-breaching dragons. And the best part? You're the king or queen, deciding who gets access to the drawbridge.</p>
<p>Read more on <a target="_blank" href="https://annietah.hashnode.dev/decentralized-web-nodes-how-they-work">Decentralized Web Nodes</a></p>
<h3 id="heading-syncing-magic-seamless-data-across-realms">Syncing Magic: Seamless Data Across Realms</h3>
<p>Web5 Sync is all about having your own team of magical assistants to make sure your data is where you need it when you need it. It’s a kind of magic that keeps your digital life in harmony across devices.</p>
<h3 id="heading-agents-the-unsung-heroes-of-web5">Agents: The Unsung Heroes of Web5</h3>
<p>In Web5, agents are loyal knights sworn to protect your digital realm. They manage the complexities of your online interactions, from securing your data to navigating the web on your behalf. Think of them as your personal digital bodyguards.</p>
<h3 id="heading-tbdex-the-financial-alchemist">tbDEX: The Financial Alchemist</h3>
<p>tbDEX is the alchemist of the financial world, transforming traditional currency into digital gold and vice versa. It's the bridge where the old world of finance shakes hands with the new digital era.</p>
<h3 id="heading-protocols-the-constitution-of-web5">Protocols: The Constitution of Web5</h3>
<p>Protocols in Web5 are comparable to the laws of a digital land. They define how data interacts and exchanges, ensuring everything happens in an orderly, fair, and secure manner. It’s democracy for your data!</p>
<h3 id="heading-verifiable-credentials-the-badge-of-honor"><strong>Verifiable Credentials: The Badge of Honor</strong></h3>
<p>Verifiable Credentials in Web5 can be compared to medals obtained in the virtual combat zone. They're undeniable proof of your achievements, identity, and trustworthiness, fortified against the forces of fraud.</p>
<h2 id="heading-web5-a-user-centric-universe"><strong>Web5: A User-Centric Universe</strong></h2>
<p>With Web5, the internet becomes more than a network; it becomes a personal, user-focused experience. For instance, it can be like going from being a face in the digital crowd to being the star of your own online show.</p>
<h2 id="heading-conclusion"><strong>Conclusion</strong></h2>
<p>Web5 isn't just a technological leap; it's a cultural revolution. It's about transforming users from passive participants to active, empowered owners of their digital lives. So, as we step into this new era, let’s embrace the change and become the architects of our digital destinies in the world of Web5. Welcome to the future, where you're not just using the web; you're defining it!</p>
<h3 id="heading-resources-to-checkout">Resources to checkout</h3>
<ol>
<li><p><a target="_blank" href="https://developer.tbd.website/docs/">Learn About Web 5.0</a></p>
</li>
<li><p><a target="_blank" href="https://www.blockchain-council.org/web-3/what-is-web-5-0-all-you-need-to-know/">What is Web 5.0 (All you need to know)</a></p>
</li>
<li><p><a target="_blank" href="https://www.linkedin.com/pulse/what-web-50-strivemindz-hgmef?trk=article-ssr-frontend-pulse_more-articles_related-content-card">What is Web 5.0 and How it differs from previous technologies</a></p>
</li>
</ol>
]]></content:encoded></item><item><title><![CDATA[Uncovering the Key to a Speedy Frontend Framework]]></title><description><![CDATA[Introduction
Discover the magic behind lightning-fast frontend frameworks that revolutionize the web development landscape! Unravel the secrets of Next.js, Vite, Astro, SvelteKit, Nuxtjs, and Qwik, as we dive deep into what makes them stand out in th...]]></description><link>https://blog.aayooluwa.com/uncovering-the-key-to-a-speedy-frontend-framework</link><guid isPermaLink="true">https://blog.aayooluwa.com/uncovering-the-key-to-a-speedy-frontend-framework</guid><category><![CDATA[Frontend Development]]></category><category><![CDATA[Web Development]]></category><category><![CDATA[Next.js]]></category><category><![CDATA[progressive web apps]]></category><category><![CDATA[web performance]]></category><dc:creator><![CDATA[Coding Pastor]]></dc:creator><pubDate>Mon, 15 May 2023 07:30:39 GMT</pubDate><enclosure url="https://cdn.hashnode.com/res/hashnode/image/stock/unsplash/FJSospSHP74/upload/3a1b48397e8ef3a75a0e32506fbfdd4c.jpeg" length="0" type="image/jpeg"/><content:encoded><![CDATA[<h2 id="heading-introduction">Introduction</h2>
<p>Discover the magic behind lightning-fast frontend frameworks that revolutionize the web development landscape! Unravel the secrets of Next.js, Vite, Astro, SvelteKit, Nuxtjs, and Qwik, as we dive deep into what makes them stand out in the world of Frontend Engineering. Embark on this exhilarating journey to uncover the key ingredients powering these high-performance frameworks and learn how they're transforming the way we create seamless, responsive, and blazing-fast web experiences.</p>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1683863547130/84ab8d51-f87e-46c4-a209-5a4df5cf9ebc.gif" alt class="image--center mx-auto" /></p>
<h2 id="heading-why-is-speed-important">Why is Speed Important?</h2>
<p>In our fast-paced world, having a quick front-end web development is like a magic recipe for making users happy, increasing engagement, achieving excellent SEO rankings, and reaching impressive conversion rates. No one wants to wait for a long time before a website loads.</p>
<p>With zippy web experiences, you can wave goodbye to bounce rates and welcome smooth navigation, letting users enjoy a truly delightful experience that paves the way for your overall business success.</p>
<h2 id="heading-key-components-of-high-performance-frameworks">Key Components of High-Performance Frameworks</h2>
<ol>
<li><p>Efficient rendering: High-performance frameworks optimize the rendering process by updating only the parts of the UI that have changed, reducing unnecessary re-renders and improving performance.</p>
</li>
<li><p>Lazy loading: This technique delays the loading of non-critical resources until they're needed, reducing the initial load time and improving the overall performance of the website.</p>
</li>
<li><p>Code splitting: By breaking down the application into smaller chunks, frameworks can load only the necessary code for a specific route or feature, reducing the initial load time and improving the user experience.</p>
</li>
<li><p>Tree shaking: This process removes unused code from the final bundle, reducing its size and improving the performance of the application.</p>
</li>
<li><p>Server-side rendering (SSR): SSR sends pre-rendered HTML to the browser, allowing for faster initial load times and improved SEO, as search engines can more easily crawl the content.</p>
</li>
<li><p>Static site generation (SSG): SSG generates static HTML files at build time, reducing server load and improving performance by serving pre-built files instead of generating them on-the-fly.</p>
</li>
<li><p>Progressive web app (PWA) support: PWAs enable web applications to behave more like native apps, offering features like offline support, push notifications, and faster load times, improving the overall user experience.</p>
</li>
</ol>
<h2 id="heading-popular-fast-frontend-frameworks-and-their-features">Popular Fast Frontend Frameworks and Their Features</h2>
<ol>
<li><p><strong>Next.js</strong>: The features of Next.js encompass a variety of advanced functionalities that optimize web development and performance. Some of the key features include:</p>
<p> a. Server-side rendering (SSR): Next.js enables developers to render web pages on the server before sending them to the client, which greatly improves the initial loading time and search engine optimization (SEO) of the application.</p>
<p> b. Static site generation (SSG): With Next.js, developers can pre-build static HTML files for each page, instead of generating them on-the-fly. This approach reduces server load and allows for faster page load times, as the pre-built files can be served directly from a CDN.</p>
<p> c. Automatic code splitting: Next.js intelligently splits the application code into smaller chunks, ensuring that only the necessary code is loaded for each page. This feature reduces the amount of data that needs to be downloaded by the browser, resulting in faster load times and a more responsive user experience.</p>
</li>
<li><p><strong>Vite</strong>: Vite provides a high-speed development server, an optimized build process, and extensive plugin support. By utilizing a fast development server, Vite ensures that developers can enjoy a seamless and efficient coding experience with minimal delays. The optimized build process significantly reduces the build time and enhances the overall performance of the application. Furthermore, Vite's comprehensive plugin support allows developers to easily integrate additional functionality and features, catering to a wide range of project requirements. This combination of features results in a more streamlined development process, ultimately leading to a better end product and a more enjoyable user experience.</p>
</li>
<li><p><strong>Astro</strong>: Empowers developers with the capability of partial hydration, which optimizes website performance by only loading the essential JavaScript components needed for a specific page. By adopting a zero-JavaScript approach by default, Astro significantly reduces the overall size and complexity of the web application, resulting in faster load times and improved user experience. Furthermore, Astro offers robust static site generation capabilities, allowing developers to create pre-rendered HTML pages that can be served quickly and efficiently, catering to a wide range of project requirements. This comprehensive suite of features ensures a more streamlined development process, ultimately leading to a superior end product and an enhanced user experience.</p>
</li>
<li><p><strong>SvelteKit</strong>: Offers an advanced, feature-rich framework that incorporates server-side rendering, static site generation, and seamless updates through Svelte's innovative reactivity system. By utilizing server-side rendering, SvelteKit enables developers to generate dynamic content that is pre-rendered on the server, resulting in faster page loads and improved overall performance. Additionally, the static site generation feature allows for the creation of pre-rendered HTML pages, which can be served swiftly and efficiently, catering to a diverse array of project requirements. SvelteKit's efficient update mechanism leverages Svelte's reactivity system to ensure that only the necessary components are updated, minimizing resource usage and enhancing the overall user experience. This all-encompassing suite of features guarantees a more streamlined development process, ultimately leading to a superior end product and an elevated user experience.</p>
</li>
<li><p><strong>Nuxt.js</strong>: Offers robust server-side rendering capabilities, advanced static site generation functionality, and seamless Vue.js integration. By incorporating these features, Nuxt.js caters to a diverse array of project requirements, streamlining the development process and ensuring a high-quality end product. With its comprehensive suite of tools, Nuxt.js enhances the overall user experience by optimizing performance, improving scalability, and providing a more intuitive development environment.</p>
</li>
<li><p><strong>Qwik</strong>: Focuses on optimized rendering, minimal JavaScript, and efficient data fetching.</p>
</li>
</ol>
<h2 id="heading-leveraging-browser-caching-and-service-workers">Leveraging Browser Caching and Service Workers</h2>
<p>First, let's talk about Browser Caching and Service workers. Browser caching is the process of storing web content like images, stylesheets, and scripts in a user's browser so that they can be quickly retrieved during subsequent visits, reducing server load and improving website performance.</p>
<p>Service workers are JavaScript scripts that run in the background of a user's browser, enabling features like offline support, push notifications, and background syncing, which help improve the overall user experience and performance of web applications.</p>
<p>Leveraging browser caching and service workers can significantly improve web performance by storing assets locally in a user's browser, reducing network requests, and enabling offline functionality. This results in faster load times and a more seamless user experience.</p>
<h2 id="heading-real-world-examples-of-fast-frontend-implementations">Real-World Examples of Fast Frontend Implementations</h2>
<ol>
<li><p>Netflix uses React for its front end, which allows efficient rendering and code splitting, ensuring a fast user experience.</p>
</li>
<li><p>Facebook employs React and Relay for efficient data fetching, reducing network overhead and improving load times.</p>
</li>
<li><p>Airbnb leverages React and Next.js for server-side rendering and static site generation, optimizing performance.</p>
</li>
<li><p>Vercel, the creator of Next.js, utilizes its own framework for server-side rendering, static site generation, and code splitting, ensuring fast load times and smooth navigation.</p>
</li>
</ol>
<h2 id="heading-future-trends-in-frontend-frameworks-and-performance-optimization">Future Trends in Frontend Frameworks and Performance Optimization</h2>
<p>Future trends in frontend frameworks and performance optimization include the increasing adoption of edge computing, which brings data processing closer to the end user, resulting in lower latency and faster load times. This shift will lead to more efficient content delivery and improved user experiences.</p>
<p>Another trend is the heightened focus on Core Web Vitals, a set of performance metrics introduced by Google to evaluate the quality of user experience on a website. As these metrics become more prominent, developers will prioritize optimizing their sites to meet these benchmarks, leading to better overall performance and user satisfaction.</p>
<p>The growth of Jamstack architecture, which emphasizes the use of pre-rendering and decoupling of frontend and backend, will continue to gain traction. This approach allows for improved site performance, easier scalability, and enhanced security, making it an attractive option for many developers.</p>
<p>WebAssembly is another technology on the rise, allowing developers to run low-level code in the browser at near-native speed. As WebAssembly gains support and matures, we can expect to see more applications leveraging its performance benefits, leading to faster and more powerful web experiences.</p>
<p>Lastly, build tools and bundlers, such as Vite, Webpack, and Rollup, will continue to evolve, offering developers more efficient ways to optimize their code and deliver high-performance applications. These improvements will lead to faster build times, better code splitting, and more streamlined workflows, ultimately enhancing the performance of frontend frameworks and web applications as a whole.</p>
<h2 id="heading-conclusion">Conclusion</h2>
<p>In conclusion, we wholeheartedly appreciate the remarkable advancements in frontend frameworks, which have been made possible by efficient rendering, lazy loading, code splitting, tree shaking, server-side rendering, static site generation, and progressive web app support.</p>
<p>Esteemed frameworks such as Next.js, Vite, Astro, SvelteKit, Nuxt.js, and Qwik have skillfully integrated these features to provide exceptional web experiences. As web development continues to progress, we eagerly anticipate the positive impact of emerging technologies like edge computing, Core Web Vitals, Jamstack architecture, WebAssembly, and enhanced build tools. These innovations promise to further elevate frontend performance, paving the way for faster, more responsive, and increasingly user-friendly websites. Thanks so much for taking the time to read this! 😊</p>
]]></content:encoded></item><item><title><![CDATA[Boost Your React Skills: Essential Tips for Every Developer]]></title><description><![CDATA[Photo by Rahul Mishra Unsplash
In this article, I'm going to reveal some super amazing React application tips that will totally boost your performance and elevate your code-writing skills! I'll be sharing all the cool stuff I know and use, but if you...]]></description><link>https://blog.aayooluwa.com/boost-your-react-skills-essential-tips-for-every-developer</link><guid isPermaLink="true">https://blog.aayooluwa.com/boost-your-react-skills-essential-tips-for-every-developer</guid><category><![CDATA[React]]></category><category><![CDATA[Web Development]]></category><category><![CDATA[JavaScript]]></category><category><![CDATA[webdev]]></category><category><![CDATA[Hashnode]]></category><dc:creator><![CDATA[Coding Pastor]]></dc:creator><pubDate>Fri, 12 May 2023 01:11:27 GMT</pubDate><enclosure url="https://cdn.hashnode.com/res/hashnode/image/upload/v1680398332519/76d012f1-c10d-4d30-8ad8-9a58f95fd740.jpeg" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>Photo by <a target="_blank" href="https://unsplash.com/@rahuulmiishra?utm_source=unsplash&amp;utm_medium=referral&amp;utm_content=creditCopyText">Rahul Mishra</a> <a target="_blank" href="https://unsplash.com/photos/glmeeU0zabw?utm_source=unsplash&amp;utm_medium=referral&amp;utm_content=creditCopyText">Unsplash</a></p>
<p>In this article, I'm going to reveal some super amazing React application tips that will totally boost your performance and elevate your code-writing skills! I'll be sharing all the cool stuff I know and use, but if you have even more incredible tips, don't hesitate to drop them in the comment section below! Let's dive right in and rock this! 🎉</p>
<ol>
<li><p>Custom Hooks: Custom hooks have this cool naming pattern: "useSomething" - so you know they're React hooks right away! You can whip them up using the built-in useState, useEffect, and useContext hooks. The best part? You can create reusable bits of logic that can be shared throughout your entire app! 🚀 So, go ahead and give Custom Hooks a try - you'll be amazed at how much they can boost your coding skills! Let's look at an example</p>
<pre><code class="lang-typescript"> <span class="hljs-keyword">import</span> { useState } <span class="hljs-keyword">from</span> <span class="hljs-string">'react'</span>
 <span class="hljs-keyword">export</span> <span class="hljs-keyword">const</span> useCounter = <span class="hljs-function">() =&gt;</span> {
     <span class="hljs-comment">// this hook is to create a counter</span>

     <span class="hljs-comment">// First:  create our counter state</span>
     <span class="hljs-keyword">const</span> [counter, setCounter] = useState(<span class="hljs-number">0</span>)

     <span class="hljs-comment">// second: write the function to increment counter</span>
     <span class="hljs-keyword">const</span> handleIncrementCounter = <span class="hljs-function">(<span class="hljs-params">e: Event</span>) =&gt;</span> {
         e.preventDefault();

         setCounter(<span class="hljs-function">(<span class="hljs-params">prev:<span class="hljs-built_in">boolean</span></span>) =&gt;</span> prev + <span class="hljs-number">1</span>);
     }

     <span class="hljs-comment">// third: create a return statement. The return statement is used to                            define what the hook will return when the hook is called</span>
     <span class="hljs-keyword">return</span> { counter, handleIncrementCounter  }
 }
</code></pre>
<p> Using it in our App.tsx file</p>
<pre><code class="lang-typescript"> <span class="hljs-keyword">import</span> React <span class="hljs-keyword">from</span> <span class="hljs-string">'react'</span>

 <span class="hljs-keyword">const</span> App = <span class="hljs-function">() =&gt;</span> {
     <span class="hljs-keyword">const</span> { counter, handleIncrementCounter } = useCounter();
     <span class="hljs-keyword">return</span> (
         &lt;&gt;
                &lt;p&gt;{counter}&lt;/p&gt;
                &lt;button onClick={handleIncrementCounter}&gt;
                     Increment Me!                             
                 &lt;/button&gt;
         &lt;/&gt;
     )
 }
</code></pre>
<p> We just created a fun little counter app together! 😊</p>
</li>
<li><p>Code-Splitting and Lazy Loading: Code Splitting is a technique used in React to split the codebase into chunks that can be loaded on demand, instead of loading the entire application upfront. This will reduce the load time and overall performance of the application. This may be hard to understand so let me break it down by using an example or can I say code-split it 😅.</p>
<p> So, imagine you're making an app with an admin page and a regular user page, right? You don't want users to load all the admin stuff they don't need, and the same goes for admins. That's where code-splitting comes in handy, my friend! 😄</p>
<p> Let us see an example of how we can implement code splitting in React.</p>
<pre><code class="lang-typescript"> <span class="hljs-keyword">import</span> React, { lazy, Suspense } <span class="hljs-keyword">from</span> <span class="hljs-string">'react'</span>;

 <span class="hljs-keyword">const</span> AdminPage = lazy(<span class="hljs-function">() =&gt;</span> <span class="hljs-keyword">import</span>(<span class="hljs-string">'./AdminPage'</span>));
 <span class="hljs-keyword">const</span> RegularUserPage = lazy(<span class="hljs-function">() =&gt;</span> <span class="hljs-keyword">import</span>(<span class="hljs-string">'./UserPage'</span>));

 <span class="hljs-function"><span class="hljs-keyword">function</span> <span class="hljs-title">App</span>(<span class="hljs-params"></span>) </span>{
   <span class="hljs-keyword">return</span> (
     &lt;div&gt;
       &lt;h1&gt;Welcome to My App&lt;/h1&gt;
       &lt;Suspense fallback={&lt;div&gt;Loading...&lt;/div&gt;}&gt;
         {isAdmin ? &lt;AdminPage /&gt; : &lt;UserPage /&gt;}
       &lt;/Suspense&gt;
     &lt;/div&gt;
   );
 }

 <span class="hljs-keyword">export</span> <span class="hljs-keyword">default</span> App;
</code></pre>
</li>
<li><p>Higher-Order Components (HOCs): Higher-order components are functions that take a component ad return a new component with additional functionality. They allow you to reuse your code and keep your components clean.</p>
<p> Let's look at an example</p>
<pre><code class="lang-typescript"> <span class="hljs-keyword">import</span> {Redirect} <span class="hljs-keyword">from</span> <span class="hljs-string">'react-router-dom'</span>

 <span class="hljs-keyword">const</span> withAuth = <span class="hljs-function">(<span class="hljs-params">Component</span>) =&gt;</span> {
     <span class="hljs-keyword">const</span> AuthenticatedComponent = <span class="hljs-function">() =&gt;</span>  {
     <span class="hljs-comment">// this is to check if the user is authenticated</span>
     <span class="hljs-keyword">const</span> isAuthenticated = <span class="hljs-literal">true</span>;

     <span class="hljs-keyword">if</span> (isAuthenticated) {
             <span class="hljs-comment">// when user is component, it will render this</span>
               <span class="hljs-keyword">return</span> &lt;Component {...props}/&gt;
         }
     <span class="hljs-keyword">else</span> {
         <span class="hljs-comment">// this will redirect the user to the login page if not authenticated</span>
             <span class="hljs-keyword">return</span> &lt;Redirect to=<span class="hljs-string">'/login'</span> /&gt;
         }
     }
 }
</code></pre>
<p> Now let's apply the Higher Order component we created</p>
<pre><code class="lang-typescript"> <span class="hljs-keyword">const</span> Profile = <span class="hljs-function">() =&gt;</span> {
     <span class="hljs-keyword">return</span> (
         &lt;&gt;
             &lt;p&gt;This is my Profile! My name is Coding Pastor&lt;/p&gt;
         &lt;/&gt;
     )
 }

 <span class="hljs-comment">// import withAuth</span>
 <span class="hljs-keyword">const</span> AuthenticatedApp = withAuth(Dashboard)
</code></pre>
<pre><code class="lang-typescript"> <span class="hljs-keyword">const</span> App = <span class="hljs-function">() =&gt;</span> {
   <span class="hljs-keyword">return</span> (
     &lt;Router&gt;
       &lt;Switch&gt;
         &lt;Route exact path=<span class="hljs-string">"/"</span> component={Home} /&gt;
         &lt;Route path=<span class="hljs-string">"/dashboard"</span> component={AuthenticatedDashboard} /&gt;
         &lt;Route path=<span class="hljs-string">"/login"</span> component={Login} /&gt;
       &lt;/Switch&gt;
     &lt;/Router&gt;
   );
 };
</code></pre>
<p> We wrapped the "Profile" component with the "withAuth" Higher-order component. This will ensure that only authenticated users can access the Profile page. Users that are not authenticated will be redirected to the login page.</p>
</li>
<li><p>Context API: Context API is a way to share data between components without passing props down through the entire component. It allows you to create a global state that can be accessed by any component in your application. It is the cure for prop drilling. Sometimes you want a state to be general and accessible throughout your whole application, instead of passing down props and digging through your application, you can use Context API to create a global state. Let's see how we can do that.</p>
<p> For this example, we will create a context that stores users' data after authentication. Creating a theme context is too common on the internet. Let's do something uncommon.</p>
<pre><code class="lang-typescript"> <span class="hljs-keyword">import</span> React, { createContext, useState } <span class="hljs-keyword">from</span> <span class="hljs-string">'react'</span>;

 <span class="hljs-keyword">export</span> <span class="hljs-keyword">const</span> AuthContext = createContext();

 <span class="hljs-keyword">const</span> AuthProvider = <span class="hljs-function">(<span class="hljs-params">{ children }</span>) =&gt;</span> {
   <span class="hljs-keyword">const</span> [isAuthenticated, setIsAuthenticated] = useState(<span class="hljs-literal">false</span>);
   <span class="hljs-keyword">const</span> [userData, setUserData] = useState(<span class="hljs-literal">null</span>);

   <span class="hljs-keyword">const</span> login = <span class="hljs-function">(<span class="hljs-params">userData</span>) =&gt;</span> {
     setIsAuthenticated(<span class="hljs-literal">true</span>);
     setUserData(userData);
   };

   <span class="hljs-keyword">const</span> logout = <span class="hljs-function">() =&gt;</span> {
     setIsAuthenticated(<span class="hljs-literal">false</span>);
     setUserData(<span class="hljs-literal">null</span>);
   };

   <span class="hljs-keyword">return</span> (
     &lt;AuthContext.Provider value={{ isAuthenticated, userData, login, logout }}&gt;
       {children}
     &lt;/AuthContext.Provider&gt;
   );
 };

 <span class="hljs-keyword">export</span> <span class="hljs-keyword">default</span> AuthProvider;
</code></pre>
<pre><code class="lang-typescript"> <span class="hljs-keyword">import</span> React <span class="hljs-keyword">from</span> <span class="hljs-string">'react'</span>;
 <span class="hljs-keyword">import</span> AuthProvider <span class="hljs-keyword">from</span> <span class="hljs-string">'./AuthProvider'</span>;
 <span class="hljs-keyword">import</span> LoginPage <span class="hljs-keyword">from</span> <span class="hljs-string">'./LoginPage'</span>;
 <span class="hljs-keyword">import</span> ProfilePage <span class="hljs-keyword">from</span> <span class="hljs-string">'./ProfilePage'</span>;

 <span class="hljs-function"><span class="hljs-keyword">function</span> <span class="hljs-title">App</span>(<span class="hljs-params"></span>) </span>{
   <span class="hljs-keyword">return</span> (
     &lt;AuthProvider&gt;
       &lt;LoginPage /&gt;
       &lt;ProfilePage /&gt;
     &lt;/AuthProvider&gt;
   );
 }

 <span class="hljs-keyword">export</span> <span class="hljs-keyword">default</span> App;
</code></pre>
<p> To access the user data;</p>
<pre><code class="lang-typescript"> <span class="hljs-keyword">import</span> React, { useContext } <span class="hljs-keyword">from</span> <span class="hljs-string">'react'</span>;
 <span class="hljs-keyword">import</span> { AuthContext } <span class="hljs-keyword">from</span> <span class="hljs-string">'./AuthProvider'</span>;

 <span class="hljs-function"><span class="hljs-keyword">function</span> <span class="hljs-title">ProfilePage</span>(<span class="hljs-params"></span>) </span>{
   <span class="hljs-keyword">const</span> { userData } = useContext(AuthContext);

   <span class="hljs-keyword">return</span> (
     &lt;div&gt;
       &lt;h1&gt;Welcome, {userData.username}!&lt;/h1&gt;
       &lt;p&gt;Email: {userData.email}&lt;/p&gt;
     &lt;/div&gt;
   );
 }

 <span class="hljs-keyword">export</span> <span class="hljs-keyword">default</span> ProfilePage;
</code></pre>
</li>
<li><p>React Hooks: This one is very common and used by every React developer., Examples of popular react hooks are the useState hooks, useEffect, useReducer, and more. React hooks provide a simpler and more concise way to manage state and lifecycle methods in your components. We already used the useState hook above. let's see others. We will not be able to touch everything</p>
<ol>
<li><p>useEffect Hook: The useEffect hook enables side effects in functional components, such as data fetching, event subscribing, or DOM updates. It takes a function and an optional dependencies array, executing the function after each render based on the dependencies. Use it wisely to prevent performance issues or bugs.</p>
<pre><code class="lang-typescript"> <span class="hljs-keyword">const</span> [data, setData] = useState(<span class="hljs-literal">null</span>);

 useEffect(<span class="hljs-function">() =&gt;</span> { 
 <span class="hljs-keyword">const</span> fetchData = <span class="hljs-keyword">async</span> () =&gt; { 
 <span class="hljs-keyword">const</span> response = <span class="hljs-keyword">await</span> fetch(<span class="hljs-string">'https://api.example.com/data'</span>); 
 <span class="hljs-keyword">const</span> result = <span class="hljs-keyword">await</span> response.json(); setData(result); 
 };

 fetchData(); }, []);

 <span class="hljs-comment">// from this code above, we are trying to render the data from the fetchData to the page.</span>
</code></pre>
</li>
<li><p>useReducer Hook: The useReducer hook manages complex state in components, providing more flexibility than useState. It requires a reducer function and initial state and returns an array with the current state and a dispatch function. While powerful, it can be more challenging than useState, especially for React beginners.</p>
<pre><code class="lang-typescript"> <span class="hljs-keyword">const</span> initialState = { count: <span class="hljs-number">0</span> };

 <span class="hljs-function"><span class="hljs-keyword">function</span> <span class="hljs-title">reducer</span>(<span class="hljs-params">state, action</span>) </span>{
   <span class="hljs-keyword">switch</span> (action.type) {
     <span class="hljs-keyword">case</span> <span class="hljs-string">'increment'</span>:
       <span class="hljs-keyword">return</span> { count: state.count + <span class="hljs-number">1</span> };
     <span class="hljs-keyword">case</span> <span class="hljs-string">'decrement'</span>:
       <span class="hljs-keyword">return</span> { count: state.count - <span class="hljs-number">1</span> };
     <span class="hljs-keyword">default</span>:
       <span class="hljs-keyword">throw</span> <span class="hljs-keyword">new</span> <span class="hljs-built_in">Error</span>();
   }
 }

 <span class="hljs-function"><span class="hljs-keyword">function</span> <span class="hljs-title">Counter</span>(<span class="hljs-params"></span>) </span>{
   <span class="hljs-keyword">const</span> [state, dispatch] = useReducer(reducer, initialState);

   <span class="hljs-keyword">return</span> (
     &lt;&gt;
       Count: {state.count}
       &lt;button onClick={<span class="hljs-function">() =&gt;</span> dispatch({ <span class="hljs-keyword">type</span>: <span class="hljs-string">'increment'</span> })}&gt;+&lt;/button&gt;
       &lt;button onClick={<span class="hljs-function">() =&gt;</span> dispatch({ <span class="hljs-keyword">type</span>: <span class="hljs-string">'decrement'</span> })}&gt;-&lt;/button&gt;
     &lt;/&gt;
   );
 }
 <span class="hljs-comment">// This is a count application with useReducer</span>
</code></pre>
</li>
<li><p>useRef: The useRef hook is a super helpful tool that lets you create and manage changeable references right inside your functional components. It's often used for directly accessing DOM elements or keeping values that stay the same across renders without making your component re-render. Pretty cool, right?</p>
<pre><code class="lang-typescript"> <span class="hljs-keyword">import</span> React, { useRef } <span class="hljs-keyword">from</span> <span class="hljs-string">'react'</span>;

 <span class="hljs-function"><span class="hljs-keyword">function</span> <span class="hljs-title">TextInput</span>(<span class="hljs-params"></span>) </span>{
   <span class="hljs-keyword">const</span> inputRef = useRef(<span class="hljs-literal">null</span>);

   <span class="hljs-keyword">const</span> focusInput = <span class="hljs-function">() =&gt;</span> {
     inputRef.current.focus();
   };

   <span class="hljs-keyword">return</span> (
     &lt;div&gt;
       &lt;input ref={inputRef} <span class="hljs-keyword">type</span>=<span class="hljs-string">"text"</span> /&gt;
       &lt;button onClick={focusInput}&gt;Focus Input&lt;/button&gt;
     &lt;/div&gt;
   );
 }

 <span class="hljs-keyword">export</span> <span class="hljs-keyword">default</span> TextInput;
</code></pre>
</li>
<li><p>useMemo: useMemo is a fantastic React hook that boosts the performance of your app by remembering the outcome of a function, so you don't have to do needless re-calculations. It needs two things: a function that gives you a value, and an array of dependencies. The magic happens when useMemo only re-does the calculation if any dependencies change. This is super handy for complex calculations or when a component keeps rendering often.</p>
<pre><code class="lang-typescript"> <span class="hljs-keyword">const</span> memoizedResult = useMemo(<span class="hljs-function">() =&gt;</span> {
   <span class="hljs-keyword">return</span> expensiveCalculationFunction(a, b);
 }, [a, b]);
</code></pre>
</li>
<li><p>useCallback: useCallback is another react hook that memorizes a callback function, preventing unnecessary re-creating of the function. It takes two arguments: The callback function and an array of dependencies. useCallback will return the memoized version of the callback function, which will only change if one of the dependencies has changed. This is useful for optimizing performance, especially when passing callbacks to child components on a frequently rendered component.</p>
<pre><code class="lang-typescript"> <span class="hljs-keyword">const</span> memoizedCallback = useCallback(<span class="hljs-function">() =&gt;</span> {
   doSomethingWith(a, b);
 }, [a, b]);
</code></pre>
<p> The use Callback hook is similar to the useMemo hook since they boost the performance of the application. The difference between the two hooks is that while the useMemo hook memoizes the result of a function, useCallback hook memoizes a callback function.</p>
</li>
</ol>
</li>
</ol>
<h2 id="heading-conclusion">Conclusion</h2>
<p>In conclusion, WOW! Utilizing React features like Custom Hooks, Code-Splitting, Higher-Order Components, Context API, and various hooks such as useState, useEffect, useReducer, useRef, useMemo, and useCallback can MASSIVELY enhance your application's performance and code quality! Embrace these AWESOME techniques to not only make your code super efficient but also skyrocket your skills as a React developer! Thank you for reading and HAPPY CODING! 🚀🎉</p>
]]></content:encoded></item><item><title><![CDATA[Goodbye create-react-app: A New Approach]]></title><description><![CDATA[Are you ready to say goodbye to an old friend? For many React developers, create-react-app has been a trusty companion in their journey of building single-page applications. It's made setting up projects a breeze and saved countless hours of configur...]]></description><link>https://blog.aayooluwa.com/goodbye-create-react-app-a-new-approach</link><guid isPermaLink="true">https://blog.aayooluwa.com/goodbye-create-react-app-a-new-approach</guid><category><![CDATA[React]]></category><category><![CDATA[Web Development]]></category><category><![CDATA[Next.js]]></category><category><![CDATA[TypeScript]]></category><category><![CDATA[JavaScript]]></category><dc:creator><![CDATA[Coding Pastor]]></dc:creator><pubDate>Mon, 24 Apr 2023 07:00:39 GMT</pubDate><enclosure url="https://cdn.hashnode.com/res/hashnode/image/stock/unsplash/UYsBCu9RP3Y/upload/61408f248f6c3f1ce297b52a796088c7.jpeg" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>Are you ready to say goodbye to an old friend? For many React developers, create-react-app has been a trusty companion in their journey of building single-page applications. It's made setting up projects a breeze and saved countless hours of configuring Babel and Webpack. But as with all good things, it's time to bid farewell. So let's take a moment to reflect on the impact of create-react-app and the exciting changes ahead.</p>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1682217527155/c59fbe55-afa4-4704-84fe-6c707984b086.gif" alt class="image--center mx-auto" /></p>
<p>For those of you who may be reading this without any prior knowledge, allow me to provide some context. A while back, I was browsing through YouTube when I came across a particular post.  </p>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1682212600100/fea82324-f14a-4d2b-80f6-60b7e3af101c.png" alt class="image--center mx-auto" /></p>
<p>I also saw something on the Tailwind CSS website when I wanted to install Tailwind in my React application</p>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1682212778640/2d3b72f5-225a-4fca-b05c-dfec08588fe3.png" alt class="image--center mx-auto" /></p>
<p>I got confused. Why are we not using create-react-app anymore? What is happening? So many questions went through my mind. </p>
<h2 id="heading-what-is-create-react-app">What is create-react-app</h2>
<p>In case you're not familiar, create-react-app is a React.js build tool and command line interface (CLI), similar to create-next-app or Next.js as some people call it. It's a super handy tool for building front-end web applications. Think of it as a user-friendly command line interface that helps you create React applications with minimal fuss and almost no configuration needed. 😊</p>
<h3 id="heading-why-create-react-app-came-into-existence">Why create-react-app came into existence</h3>
<p>Initially, setting up your react project used to be a daunting task for beginners in react.js. from setting installing React-dom, and React to setting up Webpack and Babel was pretty overwhelming. Sometimes one may give up in the process of just trying to install them. </p>
<p>CRA allowed developers to use ES6 syntax with their React applications and eliminated the need for manual configuration, making it easier and faster to get started with building front-end web applications.</p>
<h3 id="heading-why-are-developers-moving-from-create-react-app">Why are developers moving from create-react-app?</h3>
<ol>
<li><p>Speed and Performance: CRA offers pretty much good performance but not until alternatives to setting up your react projects and building your react projects came into existence. Frameworks such as Vite, Next.js, and Astro offer very fast build time and better performance as compared to CRA. With the release of the latest version of Vite, which is extremely fast, Next.js which is not also sleeping in terms of speed, and Astro which is like the flash of them all. Sometimes I wonder how fast we want our websites to load and maybe very soon websites will even load before the user clicks the search button. Lol, I'm just teasing 😅.</p>
</li>
<li><p>Control: This is not a major concern, but a concern is still a concern. Some developers, prefer to have more control over what they do and CRA does not offer total control. CRA abstracts away a lot of the configuration that goes into setting up a React project. Even though this is great for beginners who are just starting, some developers with a lot of experience just want to be able to control the configuration of their projects.</p>
</li>
</ol>
<h2 id="heading-alternatives-to-cra">Alternatives to CRA</h2>
<p>In the world of React Frontend, there are several options. When I say several, I mean many options. Many React frontend frameworks offer better performance and speed.</p>
<ol>
<li><p><a target="_blank" href="https://astro.build">Astro</a>: I put this first cause I have been using this lately to build my frontend applications. It is incredibly fast and it will give you a very good developer experience. One thing I love about Astro is the way it returns the error. It will tell you the error and what is supposed to be there. Not some gibberish that will get you confused.</p>
</li>
<li><p><a target="_blank" href="https://nextjs.org/docs/getting-started">Next.js</a>: Next.js can be considered a full-stack framework as well, but it is built on top of React, offering features like server-side rendering and code splitting. The speed and performance of Next.js are exceptional, making it an excellent choice for developers looking to create fast, efficient, and complex applications.</p>
</li>
<li><p><a target="_blank" href="https://vitejs.dev/guide/">Vite</a>: Vite is a build tool and a development server that is used to build modern web applications. When you combine Vite with React, then we have? I don't know, I will leave it to you to complete it yourself. The latest version of Vite which was released some days ago is the Vite 4.3 version is just so fast. We are not going to be talking about how fast these frameworks may be in another article. However, Vite 4.3 is fast. I tried it out when some hours after it was released and I was shocked. We are going to use an article to check out the speed of these front-end frameworks soon.</p>
</li>
<li><p><a target="_blank" href="https://remix.run/">Remix</a>: Remix is a React framework for building web applications. It is built on top of React and offers features such as server-side rendering, data loading, and routing. Remix focuses on developer experience and performance, delivering a simplified API and quick build times. It serves as an alternative to traditional server-side rendering frameworks such as Next.js.</p>
</li>
<li><p><a target="_blank" href="https://www.gatsbyjs.com/">Gatsby</a>: Gatsby is a popular React-based framework for building static websites and web applications. It offers features such as server-side rendering, pre-fetching, and code splitting to improve website performance and user experience. I have not used this framework but hey! if the internet says it's fast then it is fast.</p>
</li>
</ol>
<h2 id="heading-is-cra-dead">Is CRA Dead?</h2>
<p>My answer is no. There are still numerous developers using CRA, and it remains a popular tool for building React applications. Perhaps it is currently struggling, but it isn't dead. If what you want isn't available in CRA, there are better options. Do you need speed? You can try any of the alternatives mentioned previously. Additionally, you should consider that the frontend world is constantly evolving, and it's important to keep up with these changes to avoid being left behind.</p>
<h2 id="heading-conclusion">Conclusion</h2>
<p>What do you think about create-react-app? Do you still enjoy using it over other tools? Feel free to share your thoughts in the comment section. I'm excited to hear from you! Thanks so much for reading this article! Your time is truly appreciated. Don't forget to like, comment, and share with others. Take care and stay groovy! ✌️☮️</p>
]]></content:encoded></item><item><title><![CDATA[Dealing with Errors like a pro in React.js]]></title><description><![CDATA[Introduction
We have all encountered errors while building our react application. Errors that will always break our application. And then, when we check our console for the type of error, we see something like this

How do we Deal with Ugly Errors Li...]]></description><link>https://blog.aayooluwa.com/dealing-with-errors-like-a-pro-in-reactjs</link><guid isPermaLink="true">https://blog.aayooluwa.com/dealing-with-errors-like-a-pro-in-reactjs</guid><category><![CDATA[React]]></category><category><![CDATA[Web Development]]></category><category><![CDATA[JavaScript]]></category><category><![CDATA[TypeScript]]></category><category><![CDATA[webdev]]></category><dc:creator><![CDATA[Coding Pastor]]></dc:creator><pubDate>Mon, 03 Apr 2023 07:00:39 GMT</pubDate><enclosure url="https://cdn.hashnode.com/res/hashnode/image/upload/v1680396045185/8ec07148-db40-48a9-8c8c-84c9b59b68aa.jpeg" length="0" type="image/jpeg"/><content:encoded><![CDATA[<h1 id="heading-introduction">Introduction</h1>
<p>We have all encountered errors while building our react application. Errors that will always break our application. And then, when we check our console for the type of error, we see something like this</p>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1680396883491/7c1132aa-e661-46a3-9e2b-01be52ddfd7c.png" alt class="image--center mx-auto" /></p>
<h1 id="heading-how-do-we-deal-with-ugly-errors-like-this">How do we Deal with Ugly Errors Like this?</h1>
<ol>
<li><h2 id="heading-by-using-error-boundaries">By Using Error Boundaries</h2>
</li>
</ol>
<p>One of the ways to deal with breaking errors in our react application is to use Mr. Error Boundary.</p>
<p>Error Boundaries in React are React Components, that catch errors within our application, log these errors and display a fallback UI. In this scenario, the application does not crash but instead, it renders a new UI where when it encounters an error.</p>
<h3 id="heading-how-to-use-error-boundaries">How to use Error Boundaries</h3>
<p>Using Error boundaries to take care of our errors is quite easy. First, let us create a React Component and name it ErrorBoundary.tsx.</p>
<p><strong>ErrorBoundary.tsx</strong></p>
<pre><code class="lang-typescript"><span class="hljs-keyword">import</span> React, { Component } <span class="hljs-keyword">from</span> <span class="hljs-string">'react'</span>

<span class="hljs-keyword">type</span> ErrorProps = {}
<span class="hljs-keyword">export</span> <span class="hljs-keyword">default</span> <span class="hljs-keyword">class</span> ErrorComponent <span class="hljs-keyword">extends</span> Component&lt;<span class="hljs-built_in">Error</span>, {errorPresent: <span class="hljs-built_in">boolean</span>}&gt; {
    <span class="hljs-keyword">constructor</span>(<span class="hljs-params">props: <span class="hljs-built_in">any</span></span>) {
        <span class="hljs-built_in">super</span>(props);
        <span class="hljs-built_in">this</span>.state = { errorPresent: <span class="hljs-literal">false</span> }

    }

    <span class="hljs-keyword">static</span> getDerivedStateFromError(error) {
        <span class="hljs-keyword">return</span> { errorPresent: <span class="hljs-literal">true</span> }
    }

    compoenentDidCatch(){

    }

    render() {
        <span class="hljs-keyword">if</span> (<span class="hljs-built_in">this</span>.state.hasError) {
            <span class="hljs-keyword">return</span>( &lt;p&gt;Something went wrong&lt;/p&gt;)
        }
        <span class="hljs-keyword">return</span> (&lt;&gt;
            { <span class="hljs-built_in">this</span>.props.children }
        &lt;/&gt;)
    }
}
</code></pre>
<p>From the code above, we used a class-based approach to write our Error Boundary component instead and not the functional-based approach. Currently, there is no way to write Error Boundaries as a functional component.</p>
<ol>
<li><h2 id="heading-by-using-react-error-boundary">By using react-error-boundary</h2>
<p> <code>react-error-boundary</code> is a simple reusable React Error Boundary Component.</p>
</li>
</ol>
<h3 id="heading-how-to-use-react-error-boundary">How to use react-error-boundary</h3>
<p>Run <code>npm install react-error-boundary</code> to install the package.</p>
<p>This is a Simple example of how to use <code>react-error-boundary</code>.</p>
<pre><code class="lang-typescript"><span class="hljs-keyword">import</span> { ErrorBoundary } <span class="hljs-keyword">from</span> <span class="hljs-string">"react-error-boundary"</span>;

<span class="hljs-function"><span class="hljs-keyword">function</span> <span class="hljs-title">fallbackRender</span>(<span class="hljs-params">{ error, resetErrorBoundary }</span>) </span>{
  <span class="hljs-comment">// Call resetErrorBoundary() to reset the error boundary and retry the render.</span>

  <span class="hljs-keyword">return</span> (
    &lt;div&gt;
      &lt;p&gt;Something went wrong:&lt;/p&gt;
      &lt;pre style={{ color: <span class="hljs-string">"red"</span> }}&gt;{error.message}&lt;/pre&gt;
    &lt;/div&gt;
  );
}

&lt;ErrorBoundary
  fallbackRender={fallbackRender}
  onReset={<span class="hljs-function">(<span class="hljs-params">details</span>) =&gt;</span> {
    <span class="hljs-comment">// Reset the state of your app so the error doesn't happen again</span>
  }}
&gt;
  &lt;MyApplication/&gt;
&lt;/ErrorBoundary&gt;;
</code></pre>
<h1 id="heading-conclusion">Conclusion</h1>
<p>In conclusion, Error Boundary does not catch errors with the following:</p>
<ul>
<li><p>Asynchronous code</p>
</li>
<li><p>Event Handlers</p>
</li>
<li><p>Server-side rendering</p>
</li>
</ul>
<p>To do this, you can use the <code>react-error-boundary</code> package.</p>
<p>Finally, we have been able to learn how to handle errors in React.js like pros.</p>
]]></content:encoded></item><item><title><![CDATA[How to change the default port for your react app]]></title><description><![CDATA[There are several ways to change the default port for your react application, Let us start with the easy one. 
Change the port from your .env file
You can create a .env file and just add the port number you want to use. Like this
PORT=4000
// .env fi...]]></description><link>https://blog.aayooluwa.com/how-to-change-the-default-port-for-your-react-app</link><guid isPermaLink="true">https://blog.aayooluwa.com/how-to-change-the-default-port-for-your-react-app</guid><category><![CDATA[React]]></category><category><![CDATA[JavaScript]]></category><category><![CDATA[Web Development]]></category><category><![CDATA[Programming Blogs]]></category><category><![CDATA[Programming Tips]]></category><dc:creator><![CDATA[Coding Pastor]]></dc:creator><pubDate>Sat, 25 Mar 2023 08:00:39 GMT</pubDate><enclosure url="https://cdn.hashnode.com/res/hashnode/image/stock/unsplash/p-xSl33Wxyc/upload/169b34aa1d943cd630f2a17bd77ae0fb.jpeg" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>There are several ways to change the default port for your react application, Let us start with the easy one. </p>
<h3 id="heading-change-the-port-from-your-env-file">Change the port from your .env file</h3>
<p>You can create a .env file and just add the port number you want to use. Like this</p>
<p><code>PORT=4000</code></p>
<pre><code class="lang-typescript"><span class="hljs-comment">// .env file</span>
PORT=<span class="hljs-number">4000</span>
</code></pre>
<p>Once you set it, you can start your react application. React will automatically start the application using the PORT number you specified.  </p>
<h3 id="heading-changing-the-port-from-your-packagejson">Changing the port from your package.json</h3>
<p>You can also change your port number from your package.json file. Let us see how. </p>
<p>Add P<code>ORT=3456</code> to the value of start on MacOS and <code>set PORT=4000</code> to the value of start on Windows.</p>
<p><strong>On macOS</strong></p>
<pre><code class="lang-typescript"><span class="hljs-string">"scripts"</span>: {
    <span class="hljs-string">"start"</span>: <span class="hljs-string">"port=4000 react-scripts start"</span>,
 },
</code></pre>
<p><strong>On Windows</strong></p>
<pre><code class="lang-typescript"><span class="hljs-string">"scripts"</span>: {
    <span class="hljs-string">"start"</span>: <span class="hljs-string">"set port=4000 &amp;&amp; react-scripts start"</span>,
 },
</code></pre>
<h3 id="heading-changing-the-port-number-from-the-terminal-or-cmd">Changing the PORT number from the Terminal or CMD</h3>
<p>Using this method, you are changing the port number using your OS's environmental variable.</p>
<pre><code class="lang-typescript"><span class="hljs-comment">// Using cmd</span>
set PORT=<span class="hljs-number">4000</span>
</code></pre>
<pre><code class="lang-typescript"><span class="hljs-comment">// using terminal, or bash</span>
<span class="hljs-keyword">export</span> PORT=<span class="hljs-number">4000</span>
</code></pre>
<pre><code class="lang-typescript"><span class="hljs-comment">// using powershell</span>
$env:PORT=<span class="hljs-number">4000</span>
</code></pre>
<p>After running this on your terminal or cmd, run <code>npm start</code> to start the project</p>
<h3 id="heading-using-the-cross-env-package">Using the cross-env package</h3>
<p>The <em>cross-env</em> package can also change your port number to a custom port. First, to be able to change our port number using this package, we will have to install, it.</p>
<p>On your terminal or command prompt, run <code>npm install cross-env</code> Once it is installed add cross-env PORT=4000 to the value of start in your <em>package.json</em></p>
<pre><code class="lang-typescript"><span class="hljs-string">"scripts"</span>: {
    <span class="hljs-string">"start"</span>: <span class="hljs-string">"cross-env PORT=4000 react-scripts start"</span>,
 },
</code></pre>
<p>After doing any of the above methods, your react app should be available on http://localhost:4000</p>
]]></content:encoded></item><item><title><![CDATA[Let's build with Astro and React]]></title><description><![CDATA[Introduction
Astro is a Multi-Page all-in-one framework to help you build modern websites fast and easily with less or no Javascript offering very high performant and neat experience websites. With Astro, you can build a website with any UI framework...]]></description><link>https://blog.aayooluwa.com/lets-build-with-astro-and-react</link><guid isPermaLink="true">https://blog.aayooluwa.com/lets-build-with-astro-and-react</guid><category><![CDATA[Astro]]></category><category><![CDATA[React]]></category><category><![CDATA[APIs]]></category><category><![CDATA[Tailwind CSS]]></category><category><![CDATA[JavaScript]]></category><dc:creator><![CDATA[Coding Pastor]]></dc:creator><pubDate>Thu, 23 Mar 2023 07:00:39 GMT</pubDate><enclosure url="https://cdn.hashnode.com/res/hashnode/image/upload/v1679369512407/41914749-eea7-4e33-bd0c-e0778de90d93.jpeg" length="0" type="image/jpeg"/><content:encoded><![CDATA[<h3 id="heading-introduction">Introduction</h3>
<p>Astro is a Multi-Page all-in-one framework to help you build modern websites fast and easily with less or no Javascript offering very high performant and neat experience websites. With Astro, you can build a website with any UI framework of your choice like Preact, Svelte, React, Vue, Solid, Lit, and other UI frameworks.</p>
<p>Click <a target="_blank" href="https://astro.new">here</a> to try Astro in your browser</p>
<h3 id="heading-what-you-will-learn">What you will learn</h3>
<p>In this tutorial, we are going to cover the basics of Astro, routing in Astro, dynamic routing in Astro, fetching APIs in Astro, and Using Astro with Reactjs</p>
<h3 id="heading-getting-started-with-astro"><strong>Getting Started With Astro</strong></h3>
<p>To build our project, first, we need to create an Astro startup project</p>
<p><code>npm create astro@latest</code></p>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1679363747760/f632d7c6-38a2-4304-adbc-9ba8d02b7e7c.png" alt /></p>
<p>After installation, your project structure should look like this</p>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1679363806385/b5ca2be0-439c-4ce1-96b3-38926206fad4.png" alt /></p>
<p>To run our Astro project, we use the command below</p>
<p><code>npm run dev</code></p>
<p>Astro ships with built-in support for typescript. We can directly write TypeScript in our Astro component. Astro components end with the extension <code>.astro</code></p>
<p>Now that we have installed Astro, let's install React. To install React, run;</p>
<p><code># Using NPM</code></p>
<p><code>npx astro add react</code></p>
<p><code># Using Yarn yarn astro add react</code></p>
<p><code># Using PNPM pnpm astro add react</code></p>
<p>We need to install the dependencies manually.</p>
<p><code>npm install @astrojs/react</code></p>
<p>Most times, the command above installs everything you need but in case you cannot find react, run this</p>
<p><code>npm install react react-dom</code></p>
<p>Now, head over to your <code>astro.config.mjs</code> file and paste this</p>
<p><code>import { defineConfig } from 'astro/config';</code></p>
<p><code>import react from '@astrojs/react';</code></p>
<p><code>export default defineConfig({</code></p>
<p><code>// ...</code></p>
<p><code>integrations: [react()],</code></p>
<p><code>})</code></p>
<h3 id="heading-styling">Styling</h3>
<p>For our styling, we are going to be using <code>tailwind css.</code>To Set up Tailwind CSS, run the command below</p>
<p>To install automatically,</p>
<p><code>npx astro add tailwind</code></p>
<p>The command above should set up the configurations and get you started. If you are facing any issue involving tailwind configuration, click this <a target="_blank" href="https://docs.astro.build/en/guides/integrations-guide/tailwind/#configuration">link</a></p>
<h3 id="heading-lets-begin-the-project">Let's begin the project</h3>
<p>Today, we are going to be building a basic movie database, to display a list of movies and also get information about the movies.</p>
<p>First, in your <code>src/</code> directory, we are going to be creating a few folders. The names of the folders are</p>
<ol>
<li><p>Component folder. This folder will house our React components.</p>
</li>
<li><p>Container. This will house our Astro components.</p>
</li>
</ol>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1679365402337/f83b96de-46ff-4c3b-a29e-69485d176fac.png" alt /></p>
<p>In the <code>src/</code> directory, you can also see the <code>pages</code> directory. The pages folder contains the pages of our app. The root page is the <code>index.astro</code> file.</p>
<p>In your container folder, create an Astro component, and name it <code>movie.astro</code></p>
<pre><code class="lang-xml">---
---

<span class="hljs-tag">&lt;<span class="hljs-name">html</span> <span class="hljs-attr">lang</span>=<span class="hljs-string">"en"</span>&gt;</span>
    <span class="hljs-tag">&lt;<span class="hljs-name">body</span>&gt;</span>
        <span class="hljs-tag">&lt;<span class="hljs-name">div</span> <span class="hljs-attr">class</span>=<span class="hljs-string">""</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">body</span>&gt;</span>
<span class="hljs-tag">&lt;/<span class="hljs-name">html</span>&gt;</span>
</code></pre>
<p>When you create the file, insert the line of code above. You now be wondering where our JS code will be written. Don't worry, I have your back.</p>
<p>In between the hyphens are where we will insert our code. For example,</p>
<pre><code class="lang-typescript">---
<span class="hljs-keyword">const</span> name: <span class="hljs-built_in">string</span> = <span class="hljs-string">"Coding Pastor"</span>
---

&lt;html&gt;
    &lt;body&gt;
        &lt;div <span class="hljs-keyword">class</span>=<span class="hljs-string">""</span>&gt;
            &lt;p&gt;My name is {name} &lt;/p&gt;
            &lt;p&gt;You see. Life Continues&lt;/p&gt;
        &lt;/div&gt;  

    &lt;/body&gt;
&lt;/html&gt;
</code></pre>
<p>To get the data for the movies, we are going to be using an API. Head over to <a target="_blank" href="https://www.themoviedb.org/">https://www.themoviedb.org</a>. Create an account. When your account has been created, go to your <em>settings</em> page to apply to get your API key.</p>
<p>Once you have been given an API key, visit the API <a target="_blank" href="https://developers.themoviedb.org/3/movies/get-popular-movies">documentation</a>. This link should take you to the API we will be using. We won't be able to consume all the APIs, we would only be consuming one which is <code>/movies/popular</code> in this tutorial.</p>
<p>Let's get back to our codebase for now. We want to create a .env file where we will set our API keys and base URI. The .env file should be created in the base directory.</p>
<p>I am going to be using a dummy API_KEY for this tutorial. Please note that the API Key here is incorrect.</p>
<pre><code class="lang-xml">// your .env file
BASE_URI=https://api.themoviedb.org/3
API_KEY=123098Iamcodingpastor2345
</code></pre>
<p>We have successfully created our .env file. Let's head back to the <code>movie.astro</code> component we created.</p>
<pre><code class="lang-typescript">---
<span class="hljs-keyword">const</span> url: <span class="hljs-built_in">string</span> = <span class="hljs-string">`<span class="hljs-subst">${<span class="hljs-keyword">import</span>.meta.env.BASEURI}</span>/movies/popular?api_key=<span class="hljs-subst">${<span class="hljs-keyword">import</span>.meta.env.API_KEY}</span>`</span>
<span class="hljs-keyword">const</span> response = <span class="hljs-keyword">await</span> fetch(url)
<span class="hljs-keyword">const</span> data = <span class="hljs-keyword">await</span> response.json()
<span class="hljs-built_in">console</span>.log(data)
---
</code></pre>
<p>From the piece of code above, we want to fetch the API to display the popular movies. If you check your terminal, you should see the data of popular movies being displayed.</p>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1679369897772/b4163412-d3e4-408d-a33e-5b1e15b088b3.png" alt="In this format" class="image--center mx-auto" /></p>
<p>When you look at the <code>url</code> too you can see we used <code>import.meta.env</code> instead of <code>process.env</code> . In Astro, when we want to get the environmental variables, we use <code>import.meta.env</code></p>
<p>To continue, let's create a react component to display our data. We could have fetched everything on the <code>movie.astro</code> component but it is nicer to have a reusable component which will save us more time and fewer lines of code.</p>
<p>In the <code>components</code> directory, create a file and name it <code>GetData.tsx</code> This component will display our data. After creating it, we can add the following line of code.</p>
<pre><code class="lang-typescript"><span class="hljs-keyword">import</span> React <span class="hljs-keyword">from</span> <span class="hljs-string">'react'</span>

<span class="hljs-keyword">type</span> Props = {
    data: <span class="hljs-built_in">any</span>
}

<span class="hljs-keyword">const</span> GetData = <span class="hljs-function">(<span class="hljs-params">{ data }: Props</span>) =&gt;</span> {
    <span class="hljs-keyword">return</span> (
        &lt;main className=<span class="hljs-string">'w-full'</span>&gt;
        &lt;div className=<span class="hljs-string">"px-4"</span>&gt;
            {
        data?.results.map(<span class="hljs-function">(<span class="hljs-params">item, index</span>) =&gt;</span> {
            <span class="hljs-keyword">return</span> (
            &lt;section key={index}&gt;
            &lt;a href={<span class="hljs-string">`<span class="hljs-subst">${category}</span>/<span class="hljs-subst">${item.id}</span>`</span>}&gt;
            &lt;div  className=<span class="hljs-string">'my-4 p-2'</span>&gt;
            &lt;img className=<span class="hljs-string">"rounded"</span> 
                src={<span class="hljs-string">`https://image.tmdb.org/t/p/w500/<span class="hljs-subst">${item.backdrop_path || 
                        item.profile_path || 
                        item.postal_path}</span>`</span>} alt=<span class="hljs-string">"images"</span> /&gt;

            &lt;p className=<span class="hljs-string">"border mt-2 border-slate-50 rounded-md hover:bg-    slate-500 w-fit p-1 text-xs"</span>&gt;
                    <span class="hljs-built_in">Date</span>: {item.release_date}
            &lt;/p&gt;
            &lt;p className=<span class="hljs-string">'font-semibold text-lg my-2'</span>&gt;
                {item.title || item.original_name || item.name}
            &lt;/p&gt;
            &lt;/div&gt;
            &lt;/a&gt;

            &lt;/section&gt;
            )
        })
            }
        &lt;/div&gt;
        &lt;/main&gt;

    )
}

<span class="hljs-keyword">export</span> <span class="hljs-keyword">default</span> GetData
</code></pre>
<p>As we have said, the component above renders our data. Now let's insert this into our <code>movie.astro</code> component.</p>
<pre><code class="lang-typescript">---
<span class="hljs-comment">// import GetData</span>
<span class="hljs-keyword">import</span> GetData <span class="hljs-keyword">from</span> <span class="hljs-string">'../../components/GetData'</span>

<span class="hljs-keyword">const</span> url: <span class="hljs-built_in">string</span> = <span class="hljs-string">`<span class="hljs-subst">${<span class="hljs-keyword">import</span>.meta.env.BASEURI}</span>/movies/popular?api_key=<span class="hljs-subst">${<span class="hljs-keyword">import</span>.meta.env.API_KEY}</span>`</span>
<span class="hljs-keyword">const</span> response = <span class="hljs-keyword">await</span> fetch(url)
<span class="hljs-keyword">const</span> data = <span class="hljs-keyword">await</span> response.json()
<span class="hljs-built_in">console</span>.log(data)
---

&lt;html&gt;
    &lt;body&gt;
        &lt;div <span class="hljs-keyword">class</span>=<span class="hljs-string">""</span>&gt;
           &lt;GetData data={data} /&gt;
        &lt;/div&gt;  
    &lt;/body&gt;
&lt;/html&gt;
</code></pre>
<p>Up till this point, this should be how our Astro component looks like. We are almost done. Now let's invite the <code>movie.astro</code> page to the <code>index.astro</code> page</p>
<p>In the <code>index.astro</code> page, import the <code>movie.astro</code> page. It can be in the format below</p>
<pre><code class="lang-typescript"><span class="hljs-keyword">import</span> Movie <span class="hljs-keyword">from</span> <span class="hljs-string">'../container/movie.astro</span>
</code></pre>
<p>After importing, we insert this page into the body of our page.</p>
<pre><code class="lang-typescript">---
<span class="hljs-keyword">import</span> Movie <span class="hljs-keyword">from</span> <span class="hljs-string">'../container/movie.astro'</span>
---

&lt;html lang=<span class="hljs-string">"en"</span>&gt;
    &lt;head&gt;
        &lt;meta charset=<span class="hljs-string">"utf-8"</span> /&gt;
        &lt;link rel=<span class="hljs-string">"icon"</span> <span class="hljs-keyword">type</span>=<span class="hljs-string">"image/svg+xml"</span> href=<span class="hljs-string">"/favicon.svg"</span> /&gt;
        &lt;meta name=<span class="hljs-string">"viewport"</span> content=<span class="hljs-string">"width=device-width"</span> /&gt;
        &lt;meta name=<span class="hljs-string">"generator"</span> content={Astro.generator} /&gt;
        &lt;title&gt;The Movie DB&lt;/title&gt;
        &lt;Navigation /&gt;


    &lt;/head&gt;
    &lt;body <span class="hljs-keyword">class</span>=<span class="hljs-string">"bg-slate-800 text-white"</span>&gt;


        &lt;section <span class="hljs-keyword">class</span>=<span class="hljs-string">""</span>&gt;
            &lt;Movie /&gt;
        &lt;/section&gt;
    &lt;/body&gt;
&lt;/html&gt;
</code></pre>
<p>Now let's see what we have done so far, to run your server use the command</p>
<p><code>npm run dev</code></p>
<p><strong>Here we go!!</strong></p>
<h3 id="heading-conclusion">Conclusion</h3>
<p>To recap, in this tutorial we talked about the basics of Astro, routing in Astro, dynamic routing in Astro, fetching APIs in Astro, and Using Astro with Reactjs.</p>
<p>You can check out the full version of the application <a target="_blank" href="https://movie-db-rho-ten.vercel.app/">here</a> and please give it a star on <a target="_blank" href="https://github.com/Aduwoayooluwa/Movie-Database">GitHub</a> here. Thank you.</p>
<p>I hope this article has been able to teach you how to start your Astro with React project and ideas. Thank you</p>
]]></content:encoded></item><item><title><![CDATA[Basics of Software Development | Simplified]]></title><description><![CDATA[Software Development is the use of a series of processes for developing, deploying, and maintaining computer software programs. Software development requires a series of processes and these processes make up the Software Development Life Cycle (SDLC)...]]></description><link>https://blog.aayooluwa.com/basics-of-software-development-simplified</link><guid isPermaLink="true">https://blog.aayooluwa.com/basics-of-software-development-simplified</guid><category><![CDATA[software development]]></category><category><![CDATA[Beginner Developers]]></category><category><![CDATA[Web Development]]></category><category><![CDATA[Mobile Development]]></category><category><![CDATA[webdev]]></category><dc:creator><![CDATA[Coding Pastor]]></dc:creator><pubDate>Sat, 29 Oct 2022 13:39:10 GMT</pubDate><enclosure url="https://cdn.hashnode.com/res/hashnode/image/upload/v1667050436722/ZwSVc2uDi.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>Software Development is the use of a series of processes for developing, deploying, and maintaining computer software programs. Software development requires a series of processes and these processes make up the Software Development Life Cycle (SDLC).</p>
<p><strong><a target="_blank" href="https://thewebgate.net/basics-of-software-development-simplified/">Click to read the full article</a>.</strong></p>
]]></content:encoded></item><item><title><![CDATA[Create  Static Website forms with fabform]]></title><description><![CDATA[What is a Static Website form
Static Website forms are simple form builders that let you handle form submissions easily with no code required. You can integrate HTML forms on your website easily. 
Static Websites offer insane load time. They are very...]]></description><link>https://blog.aayooluwa.com/create-static-website-forms-with-fabform</link><guid isPermaLink="true">https://blog.aayooluwa.com/create-static-website-forms-with-fabform</guid><category><![CDATA[Web Development]]></category><category><![CDATA[webdev]]></category><category><![CDATA[Frontend Development]]></category><category><![CDATA[HTML5]]></category><category><![CDATA[forms]]></category><dc:creator><![CDATA[Coding Pastor]]></dc:creator><pubDate>Thu, 28 Jul 2022 07:55:21 GMT</pubDate><enclosure url="https://cdn.hashnode.com/res/hashnode/image/upload/v1658965451664/MMmIjkofv.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<h2 id="heading-what-is-a-static-website-form">What is a Static Website form</h2>
<p><a target="_blank" href="https://fabform.io">Static Website forms</a> are simple form builders that let you handle form submissions easily with no code required. You can integrate HTML forms on your website easily. </p>
<p>Static Websites offer insane load time. They are very secure and straightforward to make use of. </p>
<h2 id="heading-what-is-fabform">What is fabform?</h2>
<p>Fabform is a free flexible Static Website form builder that provides a powerful backend for your forms. </p>
<p><a target="_blank" href="https://fabform.io">Fabform</a> has come to take creating <a target="_blank" href="https://fabform.io">static website forms</a> to the next level. It offers unique features and integrating it does not require javascript. You can set where you want the responses to be delivered, and create an email template and also a response text.</p>
<p>All you need to do is add the fabform endpoint to the <code>action</code> attribute on your <code>&lt;form&gt;</code> tag. Are you surprised? It is as easy as that.</p>
<h3 id="heading-key-features">Key Features</h3>
<ol>
<li>Create your form easily in seconds.</li>
<li>Fabform validates your form data server-side and uses AI to protect you from spam.
Fabform protects you from spam by using an AI using a form captcha.</li>
<li>Create customized email templates.
You can create customized email templates using fabform and even customized response mail. In addition, auto responses and email notifications are sent. </li>
<li>View form submissions, see daily analytics reports, and export to CSV or JSON.  </li>
<li>Works with Airtable, Email, Google Sheets, and others.</li>
</ol>
<p>In addition to all these features, fabform organizes your workflow and takes your data where it is needed, without the use of Zapier, unlike some other static form builders.</p>
<h2 id="heading-how-to-create-a-static-website-form-with-fabform">How to create a Static Website form with fabform?</h2>
<p>To create a <a target="_blank" href="https://fabform.io">static website form</a> with fabform, create an account with fabform. </p>
<ol>
<li>Sign up for fabform <a target="_blank" href="https://app.fabform.io/signup">here</a>
<img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1658967555200/6ViaVKp4X.png" alt="fabform sign up.png" /></li>
<li>Click on "Create Endpoint" and Enter type in a name for your endpoint
<img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1658968046479/1qcQtNH2G.png" alt="create endpoints.png" /></li>
<li>Copy your endpoint and save it somewhere. That is what you will use when integrating <a target="_blank" href="https://fabform.io">fabform</a></li>
</ol>
<h3 id="heading-integrating-fabform-on-your-websites-form">Integrating fabform on your Website's Form</h3>
<p>On your form's HTML code, insert the <code>https://fabform.io/f/{your-endpoint}</code>.  For example, </p>
<pre><code><span class="hljs-operator">&lt;</span>form  action<span class="hljs-operator">=</span><span class="hljs-string">'https://fabform.io/f/{your-endpoint}'</span> method<span class="hljs-operator">=</span><span class="hljs-string">"post"</span><span class="hljs-operator">&gt;</span>
  <span class="hljs-operator">&lt;</span>label <span class="hljs-keyword">for</span><span class="hljs-operator">=</span><span class="hljs-string">"firstName"</span><span class="hljs-operator">&gt;</span>First Name<span class="hljs-operator">&lt;</span><span class="hljs-operator">/</span>label<span class="hljs-operator">&gt;</span>
  <span class="hljs-operator">&lt;</span>input name<span class="hljs-operator">=</span><span class="hljs-string">"firstName"</span> <span class="hljs-keyword">type</span><span class="hljs-operator">=</span><span class="hljs-string">"text"</span> required<span class="hljs-operator">&gt;</span>
  <span class="hljs-operator">&lt;</span>label <span class="hljs-keyword">for</span><span class="hljs-operator">=</span><span class="hljs-string">"lastName"</span><span class="hljs-operator">&gt;</span>Last Name<span class="hljs-operator">&lt;</span><span class="hljs-operator">/</span>label<span class="hljs-operator">&gt;</span>
  <span class="hljs-operator">&lt;</span>input name<span class="hljs-operator">=</span><span class="hljs-string">"lastName"</span> <span class="hljs-keyword">type</span><span class="hljs-operator">=</span><span class="hljs-string">"text"</span> required<span class="hljs-operator">&gt;</span>
  <span class="hljs-operator">&lt;</span>label <span class="hljs-keyword">for</span><span class="hljs-operator">=</span><span class="hljs-string">"email"</span><span class="hljs-operator">&gt;</span>Email<span class="hljs-operator">&lt;</span><span class="hljs-operator">/</span>label<span class="hljs-operator">&gt;</span>
  <span class="hljs-operator">&lt;</span>input name<span class="hljs-operator">=</span><span class="hljs-string">"email"</span> <span class="hljs-keyword">type</span><span class="hljs-operator">=</span><span class="hljs-string">"email"</span> required<span class="hljs-operator">&gt;</span>
  <span class="hljs-operator">&lt;</span>button class<span class="hljs-operator">=</span><span class="hljs-string">"button is-link"</span> <span class="hljs-keyword">type</span><span class="hljs-operator">=</span><span class="hljs-string">"submit"</span><span class="hljs-operator">&gt;</span>Test Form<span class="hljs-operator">&lt;</span><span class="hljs-operator">/</span>button<span class="hljs-operator">&gt;</span>
<span class="hljs-operator">&lt;</span><span class="hljs-operator">/</span>form<span class="hljs-operator">&gt;</span>
</code></pre><p>To set and edit your endpoint, click on the setting icon on the right side.</p>
<h2 id="heading-conclusion">Conclusion</h2>
<p>In this article, we talked about static website forms and how to use fabform to create a static website form. We also saw the key features of fabform, how easy it is to integrate it, and why you should use it in your next project.</p>
<p>Thank you for taking the time to read this article. </p>
]]></content:encoded></item><item><title><![CDATA[Jokes only programmers will understand]]></title><description><![CDATA[You are probably tired now after debugging a code for several minutes or hours. You need to cool off. It isn't an easy thing to become a programmer. You need some minutes to at least laugh and forget the stress you've been through. 
It is only a prog...]]></description><link>https://blog.aayooluwa.com/jokes-only-programmers-will-understand</link><guid isPermaLink="true">https://blog.aayooluwa.com/jokes-only-programmers-will-understand</guid><category><![CDATA[Programming Blogs]]></category><category><![CDATA[Web Development]]></category><category><![CDATA[Programming Tips]]></category><category><![CDATA[Beginner Developers]]></category><category><![CDATA[General Programming]]></category><dc:creator><![CDATA[Coding Pastor]]></dc:creator><pubDate>Fri, 08 Jul 2022 07:00:00 GMT</pubDate><enclosure url="https://cdn.hashnode.com/res/hashnode/image/upload/v1657244526565/ZJNw5MzNp.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>You are probably tired now after debugging a code for several minutes or hours. You need to cool off. It isn't an easy thing to become a programmer. You need some minutes to at least laugh and forget the stress you've been through. </p>
<p>It is only a programmer that will understand what it takes and the stress involved in programming. </p>
<p>To understand these jokes, you have to be a programmer, and if you're not don't worry. Laugh and also share them with your friends that are programmers. </p>
<p>I had to search the internet to collect these random programming jokes. So the title should have been  <em>Random programming jokes around the internet 😅</em>.  Will you get all of them? How great is your sense of humor? Let's see</p>
<ol>
<li><p><strong>There are 10 types of people in this world. Those who understand binary and those who don't.</strong> Okay, did you laugh? or did you not get it? First, this is a binary joke. Binary contains two digits, 0 and 1. </p>
</li>
<li><p>The best thing about Boolean is even if you are wrong, you are only off by a bit </p>
</li>
<li><p>A son asked his father (a programmer) why the sun rises in the east, and sets in the west. His response? It works, don’t touch it!</p>
</li>
<li><p>Copy-and-Paste was programmed by programmers for programmers actually.</p>
</li>
<li><p>What is an Algorithm?  A Word used by programmers when they don’t want to explain what they did.</p>
</li>
<li><p>Software, churches, and cathedrals are much the same — first we build them, then we pray</p>
</li>
<li><p>There are two ways to write error-free programs; only the third works.</p>
</li>
<li><p>If debugging is the process of removing bugs, then programming must be the process of putting them in.</p>
</li>
<li><p>The Best way to debug a code? Delete the code 😅</p>
</li>
<li><p>What's the Object-oriented way to become Wealthy? Inheritance 🤣</p>
</li>
<li><p>Why did the programmer quit his job? Because he didn't get arrays (a raise)</p>
</li>
<li><p>Why do Java Programmers wear glasses? They don't C# 😂
This one got me hard. They don't see sharp</p>
</li>
<li><p>A programmer had a problem, he decide to use Java. He now has a ProblemFactory.</p>
</li>
<li><p>A story: Once upon a time, 3 Database SQL walked into a NoSQL bar. They walked out. Do you know why? There was no table. </p>
</li>
<li><p>The programmer got stuck in a shower because of the instructions on the shampoo state: </p>
<blockquote>
<p><strong>Lather, Rinse, Repeat</strong></p>
</blockquote>
</li>
<li><p>What did the Java code say to the C code? You’ve got no class. 😅</p>
</li>
<li><p>Two bytes meet. The first byte asks, ‘Are you ill?’ The second byte replies, ‘No, just feeling a bit off.</p>
</li>
<li><p>ASCII stupid question, get a stupid ANSI. 😂</p>
</li>
</ol>
<h3 id="heading-others">Others</h3>
<p><strong>There are two types of people</strong></p>
<pre><code><span class="hljs-keyword">if</span> (condition) {
   <span class="hljs-keyword">return</span> <span class="hljs-keyword">statement</span>;
}
</code></pre><pre><code><span class="hljs-keyword">if</span> (condition)
{
<span class="hljs-keyword">return</span> <span class="hljs-keyword">statement</span>;
}
</code></pre><p>which of them are you? </p>
<p><strong>When I wrote this code, only God and I understood what I did. Now only God knows</strong></p>
<p><strong>If debugging is the process of removing bugs, then programming must be the process of putting them in.</strong></p>
<p><strong>Why was the JavaScript developer sad? Because they didn't Node how to Express himself</strong></p>
<p><strong>How do you comfort a JavaScript bug? You console it</strong></p>
<p><strong>Two JavaScript variables are in a bar. "I'm sorry I cannot be with you, your so not my Type.", one says. The other Recasts and they lived happily ever after.</strong></p>
<p><strong>Q: Why did the React class component feel relieved?</strong>
A: Because it was off the hook</p>
<p><strong>Don't trust JavaScript programmers. All they do is promises but they never callback.</strong></p>
<p>Do you want to know something? <em>this</em> is a javascript joke</p>
<p>Thank you for taking out time to read the article.  I wish you fewer bugs in your code and remember if it works don't touch😅. Have a great day ahead.</p>
<p><em>Are you on Twitter? Follow me now and let's <a target="_blank" href="https://twitter.com/CodingPastor">connect</a> 🤗</em></p>
<h3 id="heading-sources">Sources:</h3>
<p>Check this <a target="_blank" href="https://levelup.gitconnected.com/programmers-jokes-made-easy-haha-f1d6a2a09b80">out</a> and also <a target="_blank" href="https://www.hongkiat.com/blog/programming-jokes/">this</a>. Explanation of some of the Jokes <a target="_blank" href="https://www.idtech.com/blog/part-i-top-10-programmer-jokes-explained-for-the-rest-of-us">here</a></p>
]]></content:encoded></item><item><title><![CDATA[Ultimate Guide to Solidity]]></title><description><![CDATA[What is Solidity?
Solidity is an object-oriented programming language for writing smart contracts. It is a high-level language for implementing smart contracts. It is the primary language for writing smart contracts in the Ethereum Blockchain. 
What ...]]></description><link>https://blog.aayooluwa.com/ultimate-guide-to-solidity</link><guid isPermaLink="true">https://blog.aayooluwa.com/ultimate-guide-to-solidity</guid><category><![CDATA[Solidity]]></category><category><![CDATA[Web3]]></category><category><![CDATA[Blockchain]]></category><category><![CDATA[Web Development]]></category><category><![CDATA[Programming Blogs]]></category><dc:creator><![CDATA[Coding Pastor]]></dc:creator><pubDate>Mon, 04 Jul 2022 08:31:51 GMT</pubDate><enclosure url="https://cdn.hashnode.com/res/hashnode/image/upload/v1656896880254/-4BmxrYdd.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<h1 id="heading-what-is-solidity">What is Solidity?</h1>
<p>Solidity is an object-oriented programming language for writing smart contracts. It is a high-level language for implementing smart contracts. It is the primary language for writing smart contracts in the Ethereum Blockchain. </p>
<h3 id="heading-what-is-a-smart-contract">What is a Smart Contract?</h3>
<p>A smart contract is a program or a piece of code that governs and controls actions within the blockchain.</p>
<p>To practice some Solidity basics, we are going to use the Remix IDE. <a target="_blank" href="remix.ethereum.org">Remix</a> is an online open-source IDE that allows us to write and deploy our smart contracts. </p>
<p>If you are a beginner and this is your first time trying the solidity language, don't worry this guide is also for you. As long as you have programming knowledge you are good to go. Even if you don't, you are also good to go. </p>
<pre><code><span class="hljs-comment">// an example of a simple smart contract</span>
<span class="hljs-meta"><span class="hljs-keyword">pragma</span> <span class="hljs-keyword">solidity</span> 0.8.11;</span>

<span class="hljs-class"><span class="hljs-keyword">contract</span> <span class="hljs-title">MyContract</span> </span>{
  <span class="hljs-comment">// Set Global public variables (make getters with "public")</span>
  <span class="hljs-keyword">uint8</span> <span class="hljs-keyword">public</span> storedNumber;

  <span class="hljs-comment">// let's create a function to change numbers by anyone. Must not be the same number</span>
  <span class="hljs-comment">// If it is, it will fail with the message "They are the same number"</span>

  <span class="hljs-function"><span class="hljs-keyword">function</span> <span class="hljs-title">changeNumber</span>(<span class="hljs-params"><span class="hljs-keyword">uint8</span> newNumber</span>) <span class="hljs-title"><span class="hljs-keyword">public</span></span> </span>{
    <span class="hljs-built_in">require</span>(storedNumber <span class="hljs-operator">!</span><span class="hljs-operator">=</span> newNumber, <span class="hljs-string">"They are the same number"</span>)
       storedNumber <span class="hljs-operator">=</span> newNumber 
  }

  <span class="hljs-comment">// This is how to return a public variable. This is already set with public</span>
  <span class="hljs-comment">// however for non public variables, this is how we create them</span>
  <span class="hljs-function"><span class="hljs-keyword">function</span> <span class="hljs-title">getCurrentNumber</span>(<span class="hljs-params"></span>) <span class="hljs-title"><span class="hljs-keyword">public</span></span> <span class="hljs-title"><span class="hljs-keyword">pure</span></span> <span class="hljs-title"><span class="hljs-keyword">returns</span></span>(<span class="hljs-params"><span class="hljs-keyword">uint8</span></span>) </span>{
    <span class="hljs-keyword">return</span> storedNumber;
  }
}
</code></pre><blockquote>
<p>This is what a smart contract looks like. </p>
</blockquote>
<p>Now let's get some fundamentals. </p>
<h2 id="heading-solidity-data-types">Solidity Data Types</h2>
<p>Data types are classifications or types which tell the computer how we want to use the data. </p>
<h3 id="heading-1-boolean"><strong>1. Boolean</strong></h3>
<p>The <code>bool</code> data type is used to represent situations that have binary results, such as 1 or 0, true or false. The 0 is false and the 1 is true. </p>
<p>The Solidity language supports both logical and comparison operators.</p>
<p><strong>Logical
</strong></p>
<p><code>!</code>  Logical Negation</p>
<p><code>&amp;&amp;</code> And</p>
<p><code>||</code> OR</p>
<p><strong>Comparison</strong>
<code>==</code> equality</p>
<p><code>!=</code> inequality</p>
<pre><code><span class="hljs-comment">// an example of the bool data type in solidity</span>
<span class="hljs-meta"><span class="hljs-keyword">pragma</span> <span class="hljs-keyword">solidity</span> 0.8.11;</span>

<span class="hljs-class"><span class="hljs-keyword">contract</span> <span class="hljs-title">MyBool</span> </span>{
      <span class="hljs-keyword">bool</span> <span class="hljs-keyword">public</span> isSet <span class="hljs-operator">=</span> True;
      <span class="hljs-keyword">bool</span> <span class="hljs-keyword">public</span> isPresent <span class="hljs-operator">=</span> False;
}
</code></pre><h3 id="heading-2-bitwise-operators">2. Bitwise Operators</h3>
<p><code>&amp;</code> And</p>
<p><code>|</code> OR</p>
<p><code>^</code>  XOR</p>
<p><code>~</code> Bitwise negation</p>
<p><code>&lt;&lt;</code> Left Shift</p>
<p><code>&gt;&gt;</code> Right Shift</p>
<h3 id="heading-3-arithmetic-operators">3. Arithmetic Operators</h3>
<p><code>+</code> Addition</p>
<p><code>-</code> Subtraction</p>
<p><code>*</code>  Multiplication</p>
<p><code>/</code> Division</p>
<p><code>%</code> Modulo</p>
<h2 id="heading-value-types-in-solidity">Value Types in Solidity</h2>
<h3 id="heading-1-addresses">1. Addresses</h3>
<p>Addresses in solidity hold a 20-byte value which represents the size of an Ethereum address. An address is a unique public key that points to a wallet where assets can be stored. </p>
<pre><code><span class="hljs-meta"><span class="hljs-keyword">pragma</span> <span class="hljs-keyword">solidity</span> ^0.8.1;</span>

<span class="hljs-class"><span class="hljs-keyword">contract</span> <span class="hljs-title">FirstProgram</span> </span>{
        <span class="hljs-keyword">address</span> <span class="hljs-keyword">public</span> walletAddress <span class="hljs-operator">=</span> <span class="hljs-string">"0x2Dc85851940eC853f63587c45751126E1877d8C0"</span>;


}
</code></pre><h3 id="heading-2-enums">2. Enums</h3>
<p><code>enums</code> or <code>enumerable</code> in solidity are used to create user-defined data types. It restricts the variable to only one of the pre-defined values. </p>
<p>Enums allow the contract more readable, and maintainable. it also reduces the errors in the contract.</p>
<pre><code><span class="hljs-meta"><span class="hljs-keyword">pragma</span> <span class="hljs-keyword">solidity</span> ^0.8.1;</span>

<span class="hljs-class"><span class="hljs-keyword">contract</span> <span class="hljs-title">MyFirst</span> </span>{

<span class="hljs-comment">// let's create an enum</span>
<span class="hljs-keyword">enum</span> <span class="hljs-title">Switch</span>  {
ON,
OFF
};

<span class="hljs-comment">// create a variable of type enum</span>
Switch switch;

<span class="hljs-comment">//create a function to turn on the light switch</span>
<span class="hljs-function"><span class="hljs-keyword">function</span> <span class="hljs-title">onSwitch</span>(<span class="hljs-params"></span>) <span class="hljs-title"><span class="hljs-keyword">public</span></span></span>{
    switch <span class="hljs-operator">=</span>  Switch.ON;
}

<span class="hljs-comment">// create a function to turn off the light switch</span>
<span class="hljs-function"><span class="hljs-keyword">function</span> <span class="hljs-title">offSwitch</span>(<span class="hljs-params"></span>) <span class="hljs-title"><span class="hljs-keyword">public</span></span> </span>{
      switch <span class="hljs-operator">=</span> Switch.OFF;
}

<span class="hljs-comment">// lastly we create a function that gets the value of the Switch</span>
<span class="hljs-function"><span class="hljs-keyword">function</span> <span class="hljs-title">switchReturn</span>(<span class="hljs-params"></span>) <span class="hljs-title"><span class="hljs-keyword">public</span></span> <span class="hljs-title"><span class="hljs-keyword">view</span></span> <span class="hljs-title"><span class="hljs-keyword">returns</span></span>(<span class="hljs-params">Switch</span>) </span>{
<span class="hljs-comment">// finally let's return the value of the Switch</span>
  <span class="hljs-keyword">return</span> Switch;
}
}
</code></pre><h2 id="heading-reference-types-in-solidity">Reference Types in Solidity</h2>
<h3 id="heading-4-arrays">4.  Arrays</h3>
<p>An array is a collection of elements of the same data type which can be identified using their location called index. </p>
<p>An array can either be dynamic or fixed. </p>
<pre><code><span class="hljs-comment">// Creating arrays in solidity</span>
<span class="hljs-keyword">address</span>[] addresses
<span class="hljs-keyword">uint256</span>[] myArray

<span class="hljs-comment">// Add to array</span>
<span class="hljs-function"><span class="hljs-keyword">function</span> <span class="hljs-title">add</span>(<span class="hljs-params"></span>) <span class="hljs-title"><span class="hljs-keyword">internal</span></span> </span>{
<span class="hljs-comment">// adding value to an array</span>
  myArray.<span class="hljs-built_in">push</span>(<span class="hljs-number">123</span>); 
}
</code></pre><p>Example of Dynamic array and fixed array</p>
<p><code>uint256[] dynamicArrays;</code></p>
<p><code>uint256[5] fixedArrays;</code></p>
<h3 id="heading-5-struct">5.  Struct</h3>
<p>Struct allows us to create more complicated data types and define our own type in form of structures.</p>
<pre><code><span class="hljs-keyword">struct</span> <span class="hljs-title">people</span> {
  <span class="hljs-keyword">string</span> name; 
  <span class="hljs-keyword">uint256</span> favoriteColor;
  <span class="hljs-keyword">uint256</span> age;

}
</code></pre><h3 id="heading-6-mapping">6. Mapping</h3>
<p>Mapping is similar to Dictionary or Hash tables in other languages. It accepts a key type and value type pair.</p>
<p>Mapping Syntax </p>
<p><code>mapping(key_type =&gt; value_type) mappingName;</code></p>
<pre><code><span class="hljs-keyword">struct</span> <span class="hljs-title">people</span> {
  <span class="hljs-keyword">string</span> name; 
  <span class="hljs-keyword">uint256</span> favoriteColor;
  <span class="hljs-keyword">uint256</span> age;

}

<span class="hljs-keyword">mapping</span>(<span class="hljs-keyword">address</span> <span class="hljs-operator">=</span><span class="hljs-operator">&gt;</span> people) bio;
<span class="hljs-keyword">address</span>[] <span class="hljs-keyword">public</span> people_bio;
</code></pre><h2 id="heading-conclusion">Conclusion</h2>
<p>In this article, we discussed Solidity and its data types, value types, and reference types. We also explained what smart contracts are and how they are connected to solidity. </p>
<p>There is going to be part 2 of this article. Follow me and subscribe to my newsletter to get notified when I publish part 2. Thank you 🤗</p>
<blockquote>
<p>Follow me on <a target="_blank" href="https://twitter.com/codingpastor">Twitter</a> and <a target="_blank" href="https://github.com/AduwoAyooluwa">Github</a></p>
</blockquote>
]]></content:encoded></item><item><title><![CDATA[What the hell is SSH?]]></title><description><![CDATA[When you want to clone a repo from GitHub, you see an option SSH. What does this mean? In this article, we are going to understand together what it means and stands for.  
First, let's think together about what SSH may mean, Sterilized server host 😏...]]></description><link>https://blog.aayooluwa.com/what-the-hell-is-ssh</link><guid isPermaLink="true">https://blog.aayooluwa.com/what-the-hell-is-ssh</guid><category><![CDATA[ssh]]></category><category><![CDATA[Web Development]]></category><category><![CDATA[technology]]></category><category><![CDATA[Programming Tips]]></category><category><![CDATA[Cloud]]></category><dc:creator><![CDATA[Coding Pastor]]></dc:creator><pubDate>Sat, 02 Jul 2022 07:00:01 GMT</pubDate><enclosure url="https://cdn.hashnode.com/res/hashnode/image/upload/v1656726451909/0eJxG3eNt.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>When you want to clone a repo from GitHub, you see an option SSH. What does this mean? In this article, we are going to understand together what it means and stands for.  </p>
<p>First, let's think together about what SSH may mean, <em>Sterilized server host</em> 😏 or <em>Service Saving Hosting</em> 😏. What was your thought, share in the comments section.</p>
<p>Okay, so enough thinking, let us dive right in. <strong>SSH</strong> stands for Secure Shell Protocol. Yes, that's what it stands for. Now that you know, do you understand what that word means? What is getting secured? and where is the shell? </p>
<p>SSH is a remote administration protocol, that allows users i.e. you and me, to access, control, and modify their remote servers over the internet. This is a lot to take in. So many words. Now let's break it down.
Take this as an example, Mr. A is a Software engineer at Hashnode. On a weekend, Mr. A was contacted from his place of work, Hashnode that something is wrong, some deprecated packages needs to be uninstalled and we have to update some other packages too. Mr. A, who has probably traveled and is far away from his workplace has been told to resolve the issue. At this point, you may think he will have to wait till Monday when he gets to his office or someone else close to the office who can handle should do it. </p>
<p>This is where our brother, SSH comes in. SSH gives you access or modification to servers remotely. So, Mr. A from his relaxation zone, resolved the issue using SSH protocol. Please don't ask me what the issue was because I don't know it 😅. When you see Mr. A, ask him.</p>
<p>You must be thinking now, I'm going to know this, it is going to make you look cool 😏. Yeah sure, but just be prepared because we are just getting started 😅. </p>
<h1 id="heading-how-does-ssh-work">How Does SSH Work?</h1>
<p>It is easy to use SSH on Mac or Linux, but you know on Windows, it's not hard but also not easy. Things are not always easy for us windows users. </p>
<p>To connect to a server using SSH, we just need a command with 3 easy parts</p>
<pre><code>ssh {<span class="hljs-keyword">user</span>}@{host}
</code></pre><p>Are you confused again, Don't worry let's continue the trip. The <code>user</code> from the command refers to the account you want to access, while the <code>host</code> is the server or computer you want to connect to.  Check this out. It is just a demo. If you run it won't work</p>
<pre><code><span class="hljs-attribute">ssh</span> root@<span class="hljs-number">111.22.333.444</span>.<span class="hljs-number">55</span>
</code></pre><p>Now you see it.</p>
<p>The SSH key tells your computer that you need a secure shell session with the other computer. Just so you know, for the time of the session, all the commands you run on your terminal or CMD is encrypted. </p>
<h2 id="heading-techniques-used-in-ssh-encryption">Techniques used in SSH Encryption</h2>
<p>As you now know that SSH uses encryption to ensure a secure sending of information between the Host computer and your computer. There are three techniques used by SSH for encryption:</p>
<ol>
<li>Symmetrical Encryption</li>
<li>Asymmetrical Encryption</li>
<li>Hashing</li>
</ol>
<h3 id="heading-1-symmetrical-encryption"><strong>1. Symmetrical Encryption</strong></h3>
<p>First, encryption is a way of converting data into code to prevent unauthorized access. </p>
<p>Symmetric encryption uses just a single key to send information from the client computer to the host computer. If I wanted to send a message to another computer, using the symmetrical encryption technique, I will have a key that encrypts the word. And inasmuch as the other computer has that same key I have, he can decrypt the word. That's it. It's just so Symmetrical. </p>
<h3 id="heading-2-asymmetric-encryption"><strong>2. Asymmetric Encryption</strong></h3>
<p>Asymmetrical encryption unlike its brother, symmetrical uses two separate keys to encrypt and decrypt a message. It may get confusing from here and it may not. These two keys are known as Public and Private keys. Combining them they both form a thing called, public-private key pair. Together, they're almost unbreakable. </p>
<p>A message sent using the sender's public key can only be decrypted if the receiver possesses the sender's private key. This makes the encryption more complicated.</p>
<p>SSH does not entirely use Asymmetric encryption. It is only used during key exchange algorithms in symmetric. During the symmetric key exchange, we need a way to generate the symmetric key without it becoming public. To get the symmetric key, we use a method called the Diffie Hellman Key Exchange. </p>
<p>Resources: <a target="_blank" href="https://www.youtube.com/watch?v=NmM9HA2MQGI">Check out for more About Asymmetric Encryption</a></p>
<h3 id="heading-3-hashing"><strong>3. Hashing</strong></h3>
<p>Hashing is another form of cryptography used in secure shell connections. One-way hash functions differ from the two stated techniques of encryption. The symmetric and asymmetric encryption techniques are not meant to decrypt anything.  They simply generate a unique value for a fixed length for each input.</p>
<p>It is easy to generate a cryptographic hash from input, but impossible to generate input from the hash. Hope you are not confused? This means that if a client should have the correct input, they can generate the cryptographic hash and compare if it is correct. </p>
<p>To verify the authenticity of a message, SSH uses Hashes. This is done using Hash-Based Message Authentication HMX. Using a hash function, each message transmitted must contain a MAC which is a hash that is generated from a symmetric key. MAC stands for Message authentication code. </p>
<h2 id="heading-passwords-or-ssh-which-is-better">Passwords or SSH - Which is better?</h2>
<p>First, it is harder to hack SSH keys which makes it more secure. SSH keys can be very long, making them more complex and difficult to hack. </p>
<h2 id="heading-resources-to-check-out"><strong>Resources to check out </strong></h2>
<p><a target="_blank" href="https://www.hostinger.com/tutorials/ssh-tutorial-how-does-ssh-work">Understanding Encryption, Ports and Connections</a></p>
<p><a target="_blank" href="https://www.digitalocean.com/community/tutorials/ssh-essentials-working-with-ssh-servers-clients-and-keys">SSH Essentials</a></p>
<p>Twitter : <a target="_blank" href="https://twitter.com/codingPastor">Follow me on Twitter</a>
Github: <a target="_blank" href="https://github.com/AduwoAyooluwa">Github</a></p>
]]></content:encoded></item><item><title><![CDATA[Understand the concept of useState() in ReactJs]]></title><description><![CDATA[The useState Hook in ReactJs allows you to implement the state variable without using a class-based component. 
First, to use the useState Hook, you import it from 'react'
import { useState } from 'react
The useState function takes two arguments; an ...]]></description><link>https://blog.aayooluwa.com/understand-the-concept-of-usestate-in-reactjs</link><guid isPermaLink="true">https://blog.aayooluwa.com/understand-the-concept-of-usestate-in-reactjs</guid><category><![CDATA[React]]></category><category><![CDATA[ReactHooks]]></category><dc:creator><![CDATA[Coding Pastor]]></dc:creator><pubDate>Mon, 07 Mar 2022 03:40:40 GMT</pubDate><enclosure url="https://cdn.hashnode.com/res/hashnode/image/upload/v1646624273048/g6RHWF3la.jpg" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>The useState Hook in ReactJs allows you to implement the state variable without using a class-based component. </p>
<p>First, to use the useState Hook, you import it from 'react'</p>
<pre><code><span class="hljs-keyword">import</span> { useState } <span class="hljs-keyword">from</span> <span class="hljs-string">'react</span>
</code></pre><p>The useState function takes two arguments; an initial state and it returns an array of two entries (the <em>current state</em> and the function that <em>updates</em> the state).</p>
<pre><code> <span class="hljs-keyword">const</span> [count, setCount] = useState(<span class="hljs-number">0</span>);
</code></pre><pre><code><span class="hljs-keyword">import</span> {useState} <span class="hljs-keyword">from</span> <span class="hljs-string">'react'</span>

<span class="hljs-function"><span class="hljs-keyword">function</span> <span class="hljs-title">NumberChange</span>(<span class="hljs-params"></span>) </span>{
 <span class="hljs-keyword">const</span> [count, setCount] = useState(<span class="hljs-number">0</span>);
}
</code></pre><p>from the code above, the <code>count</code>  is the current state while the <code>setCount</code> function is used to update our state. </p>
<p>We then set our initial state to zero <code>useState(0)</code></p>
<p>Let us look at an example. We will change the number from its initial value of zero (0) to another value. </p>
<pre><code><span class="hljs-keyword">import</span> { <span class="hljs-title">useState</span> } <span class="hljs-title"><span class="hljs-keyword">from</span></span> <span class="hljs-string">"react"</span>;

<span class="hljs-function"><span class="hljs-keyword">function</span> <span class="hljs-title">NumberChange</span>(<span class="hljs-params"></span>) </span>{
  const [count, setCount] <span class="hljs-operator">=</span> useState(<span class="hljs-number">0</span>);

  <span class="hljs-keyword">return</span> <span class="hljs-operator">&lt;</span>h1<span class="hljs-operator">&gt;</span>The First Number <span class="hljs-keyword">is</span>  {count}<span class="hljs-operator">&lt;</span><span class="hljs-operator">/</span>h1<span class="hljs-operator">&gt;</span>
}
</code></pre><p>Now, let's update the state</p>
<pre><code><span class="hljs-keyword">import</span> { <span class="hljs-title">useState</span> } <span class="hljs-title"><span class="hljs-keyword">from</span></span> <span class="hljs-string">'react'</span>

<span class="hljs-title"><span class="hljs-keyword">function</span></span> <span class="hljs-title">NumberChange</span>() {
 <span class="hljs-title">const</span>[<span class="hljs-title">count</span>, <span class="hljs-title">setCount</span>] <span class="hljs-operator">=</span> <span class="hljs-title">useState</span>(0);

<span class="hljs-keyword">return</span>(
    <span class="hljs-operator">&lt;</span>div<span class="hljs-operator">&gt;</span>
             <span class="hljs-operator">&lt;</span>h1<span class="hljs-operator">&gt;</span>The First Number <span class="hljs-keyword">is</span>  {count}<span class="hljs-operator">&lt;</span><span class="hljs-operator">/</span>h1<span class="hljs-operator">&gt;</span>
             <span class="hljs-operator">&lt;</span>button onClick <span class="hljs-operator">=</span> {() <span class="hljs-operator">=</span><span class="hljs-operator">&gt;</span> 
                    setCount(<span class="hljs-number">1</span>);
                }<span class="hljs-operator">&gt;</span><span class="hljs-operator">&lt;</span><span class="hljs-operator">/</span>button<span class="hljs-operator">&gt;</span>
    <span class="hljs-operator">&lt;</span><span class="hljs-operator">/</span>div<span class="hljs-operator">&gt;</span>
)

}
</code></pre>]]></content:encoded></item><item><title><![CDATA[What is Web 3.0? Is it all hype?]]></title><description><![CDATA[The internet has grown from Web 1.0 to Web 2.0 and now it is moving into Web 3.0. Web 3.0 ensures safe interactions between two parties and ensures privacy between them. Unlike Web 2.0, Web 3.0 scraps the middle-man out of the interaction. Let’s look...]]></description><link>https://blog.aayooluwa.com/what-is-web-30-is-it-all-hype</link><guid isPermaLink="true">https://blog.aayooluwa.com/what-is-web-30-is-it-all-hype</guid><category><![CDATA[Web3]]></category><category><![CDATA[internet]]></category><category><![CDATA[technology]]></category><dc:creator><![CDATA[Coding Pastor]]></dc:creator><pubDate>Thu, 03 Mar 2022 10:23:20 GMT</pubDate><enclosure url="https://cdn.hashnode.com/res/hashnode/image/unsplash/oMpAz-DN-9I/upload/v1646303263433/B81rBUriW.jpeg" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1646303212514/Jj3DVdwtC.jpg" alt="download (1).jpg" />
The internet has grown from Web 1.0 to Web 2.0 and now it is moving into Web 3.0. Web 3.0 ensures safe interactions between two parties and ensures privacy between them. Unlike Web 2.0, Web 3.0 scraps the middle-man out of the interaction. Let’s look at them one after another and then dive into Web 3.0.</p>
<p>Web 3.0 has come into existence to remove the middle-men in interactions. In Web 2, for an interaction to be performed, there would be a middle-man, an intermediary. They extract interactions that are just between two parties. We appreciate these platforms because, without them, there won’t be a way to interact with our other party. Web 3 came into existence to end the intermediary.</p>
<p>With cryptocurrencies like Bitcoin and Ethereum, we can now have a peer-to-peer interaction without a middle-man and intermediary. With bitcoin, we can perform financial interactions without intermediaries.</p>
<p><a target="_blank" href="https://thewebgate.net/what-is-web-3-0/"><strong>Read More Here</strong></a></p>
<p>Source : <a target="_blank" href="https://thewebagate.net">ThewebGate</a></p>
]]></content:encoded></item><item><title><![CDATA[DARQ – The Futuristic Technology]]></title><description><![CDATA[The world is moving into emerging technologies. These technologies are the cause of futuristic innovations and transformation happening now. These technologies are known as DARQ. It is an acronym that stands for distributed ledger technology, Artific...]]></description><link>https://blog.aayooluwa.com/darq-the-futuristic-technology</link><guid isPermaLink="true">https://blog.aayooluwa.com/darq-the-futuristic-technology</guid><category><![CDATA[technology]]></category><category><![CDATA[Web Development]]></category><dc:creator><![CDATA[Coding Pastor]]></dc:creator><pubDate>Tue, 01 Mar 2022 17:32:51 GMT</pubDate><enclosure url="https://cdn.hashnode.com/res/hashnode/image/upload/v1646155827632/jw9wTTTVB.jpg" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>The world is moving into emerging technologies. These technologies are the cause of futuristic innovations and transformation happening now. These technologies are known as DARQ. It is an acronym that stands for distributed ledger technology, Artificial Intelligence, Extended Reality (XR), and Quantum computing. These makeups DARQ and they are the powerhouses of the future.</p>
<p><a target="_blank" href="https://thewebgate.net/darq-the-futuristic-technology/">Read More Here</a></p>
]]></content:encoded></item><item><title><![CDATA[The Julia Programming Language]]></title><description><![CDATA[Julia, sounds familiar, right?  It is an open-source high-level, dynamic programming language. It is a general multi-purpose language that can be used in many areas of application. It was written in C++ as many other languages too. It was developed i...]]></description><link>https://blog.aayooluwa.com/the-julia-programming-language</link><guid isPermaLink="true">https://blog.aayooluwa.com/the-julia-programming-language</guid><category><![CDATA[Data Science]]></category><category><![CDATA[Web Development]]></category><category><![CDATA[Machine Learning]]></category><dc:creator><![CDATA[Coding Pastor]]></dc:creator><pubDate>Tue, 01 Mar 2022 10:11:55 GMT</pubDate><enclosure url="https://cdn.hashnode.com/res/hashnode/image/upload/v1646129172004/WhjYXqU2E.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1646129172004/WhjYXqU2E.png" alt="Black Moon Blog Banner.png" /></p>
<p>Julia, sounds familiar, right?  It is an open-source high-level, dynamic programming language. It is a general multi-purpose language that can be used in many areas of application. It was written in C++ as many other languages too. It was developed in 2012 by Jeff Bezanson and his team. </p>
<p>I started with the Julia programming language 2020, during the corona outbreak. Now, I had just started my Data Science course and I got to know this language whose name sounded odd, <strong>Julia</strong>. At first, I did not know it was a language, I thought it was a python framework. Afterward, I learned it, and Jeez found out it is a language worth trying. </p>
<pre><code><span class="hljs-function"><span class="hljs-keyword">function</span> <span class="hljs-title">f</span>(<span class="hljs-params"></span>)
           <span class="hljs-title">println</span>(<span class="hljs-params"><span class="hljs-string">"I love Julia"</span></span>)
       <span class="hljs-title">end</span></span>
</code></pre><p>Julia is a fast scripting language that has various applications. </p>
<h2 id="heading-applications-of-julia">Applications of Julia</h2>
<ol>
<li>Data Science</li>
<li>Machine Learning</li>
<li>Web Development</li>
<li>Data Visualization</li>
</ol>
<h3 id="heading-data-science">Data Science</h3>
<p>This should probably have rung a bell in you. Data Science is an area of study that deals with chunks of data being processed. From the two words, data and science. Science on its own is the systematic study of the behavior of a particular thing. So in combination with the word Data, it is the study of the behavior of Data. Processing and analyzing these data is what Data Science to predict the outcome of an event, find an unseen pattern, gain more information and make decisions is all about. For all this, we use modern tools and techniques which will be listed below.</p>
<p><strong>Techniques used in Data Science</strong></p>
<ol>
<li>Regression</li>
<li>Clustering</li>
<li>Decision Trees</li>
<li>Random Forests</li>
<li>Visualization</li>
<li>Probability and Statistics</li>
</ol>
<p><a target="_blank" href="https://julialang.org/#tab-ds">Read More about using Julia for Data Science here.</a></p>
<h3 id="heading-machine-learning">Machine Learning</h3>
<p>This should sound familiar too. If you haven't heard this before, then this confirms you are an alien. So, if you have not heard this word before, in simple terms Machine Learning means Machine Learning(i.e a <strong>machine</strong> that <strong>learns</strong>). Now, since we all know what Machine learning is all about, let's drive. </p>
<p>Machine learning is the study of computer algorithms that can improve automatically through experience and by the use of data. It deals with you providing a system with so much data that it will learn from. This will enable the system to predict future occurrences and events.</p>
<p>The Julia programming language uses the <em>MLJ.jl</em> package to provide a unified interface to common machine learning algorithms, which include generalized linear models, decision trees, and clustering. You are now almost confused with what the text in italic means, right? Do not worry, I am with you in this. It is just a package in Julia for Machine learning that contains several modules. </p>
<h3 id="heading-web-development">Web Development</h3>
<p>This is the most common of them all. You have surely heard of Web development and you know what it means. The Julia programming language uses Genie.jl, a full-stack web framework that provides a streamlined and efficient workflow for developing modern web applications. </p>
<p>The Julia programming language can also be used to write web UI or native UIs, and also for scripting or automation. </p>
]]></content:encoded></item><item><title><![CDATA[What does Html's "href" mean?]]></title><description><![CDATA[You've seen the href so many times when you write your HTML codes.  It stands for HypertextREFerence For example,
<a href='http://example.com'>What does Href mean?</>
From the code above, the href is an attribute within an anchor tag 
<a></a>, which ...]]></description><link>https://blog.aayooluwa.com/what-does-htmls-href-mean</link><guid isPermaLink="true">https://blog.aayooluwa.com/what-does-htmls-href-mean</guid><category><![CDATA[HTML5]]></category><category><![CDATA[Web Development]]></category><dc:creator><![CDATA[Coding Pastor]]></dc:creator><pubDate>Sun, 27 Feb 2022 12:22:53 GMT</pubDate><enclosure url="https://cdn.hashnode.com/res/hashnode/image/upload/v1645964419387/xrqX4J8Mj.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1645964419387/xrqX4J8Mj.png" alt="Minimalist Aesthetic Lifestyle Blog YouTube Banner.png" />
You've seen the href so many times when you write your HTML codes.  It stands for <strong>H</strong>ypertext<strong>REF</strong>erence For example,</p>
<pre><code><span class="hljs-operator">&lt;</span>a href<span class="hljs-operator">=</span><span class="hljs-string">'http://example.com'</span><span class="hljs-operator">&gt;</span>What does Href mean?<span class="hljs-operator">&lt;</span><span class="hljs-operator">/</span><span class="hljs-operator">&gt;</span>
</code></pre><p>From the code above, the <em>href</em> is an attribute within an anchor tag 
<code>&lt;a&gt;&lt;/a&gt;</code>, which is used to identify sections within a document or to create a link to a page. </p>
]]></content:encoded></item></channel></rss>