<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: kbartsch</title>
    <description>The latest articles on DEV Community by kbartsch (@mor3).</description>
    <link>https://dev.to/mor3</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F3130505%2Fd264d109-441f-4366-ada1-54bea81a0f9f.png</url>
      <title>DEV Community: kbartsch</title>
      <link>https://dev.to/mor3</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/mor3"/>
    <language>en</language>
    <item>
      <title>NEWSARC.io: A New Way to See the World — Perspective on a Timeline</title>
      <dc:creator>kbartsch</dc:creator>
      <pubDate>Tue, 17 Jun 2025 10:32:22 +0000</pubDate>
      <link>https://dev.to/mor3/newsarcio-a-new-way-to-see-the-world-perspective-on-a-timeline-4pog</link>
      <guid>https://dev.to/mor3/newsarcio-a-new-way-to-see-the-world-perspective-on-a-timeline-4pog</guid>
      <description>&lt;h3&gt;
  
  
  NEWSARC.io: A New Way to See the World — Perspective on a Timeline
&lt;/h3&gt;

&lt;blockquote&gt;
&lt;p&gt;&lt;strong&gt;Introduction:&lt;/strong&gt; Have you ever felt like you’re only seeing &lt;em&gt;part&lt;/em&gt; of the story?&lt;/p&gt;

&lt;p&gt;Imagine standing in a room with just one tiny window. Every day, you look through it and see the same view. It becomes familiar — comforting, even — but deep down, you know there’s more out there.&lt;/p&gt;

&lt;p&gt;That’s how reading the news often feels for me.&lt;/p&gt;

&lt;p&gt;While trying to understand global events — wars, politics, markets, climate crises — I kept hitting the same wall: limited perspectives, missing context, and headlines that seemed to nudge me toward a conclusion rather than help me form one myself. I didn’t want pre-packaged opinions. I wanted the full picture and to be able to research myself.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;h3&gt;
  
  
  👨‍💻 How NEWSARC Was Born
&lt;/h3&gt;

&lt;p&gt;As a developer (and, let’s be honest, a bit of a news junkie recently), I began searching for better tools to navigate the chaos of modern news. That’s when I discovered various free tier news apis like &lt;a href="https://finlight.me" rel="noopener noreferrer"&gt;finlight.me&lt;/a&gt; — one of many fascinating news API that opened some exciting possibilities for me.&lt;/p&gt;

&lt;p&gt;I started experimenting, building a side project to bring different viewpoints together in one place. What began as a curiosity quickly became a mission with some friends. I got in touch with the developers at Finlight, shared my vision, and we started collaborating closely to shape a platform that might make a real change. Eventually, I joined forces with them — NEWSARC was born.&lt;/p&gt;

&lt;h3&gt;
  
  
  🧭 What is NEWSARC?
&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;NEWSARC&lt;/strong&gt; isn’t your typical news platform.&lt;/p&gt;

&lt;p&gt;It’s a growing space designed to help people step outside their “news bubble” and &lt;em&gt;see the bigger picture&lt;/em&gt;.&lt;br&gt;&lt;br&gt;
 Our mission? To make it easier — and more enjoyable — to explore the full context behind global events. See timelines and make researching in the past easier and more comfortable.&lt;/p&gt;

&lt;p&gt;We collect stories from a wide range of sources and connect them into one simple, powerful interface that helps you:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;✅ &lt;strong&gt;View diverse perspectives side-by-side&lt;/strong&gt;
See how different media outlets cover the same event, and spot patterns, contradictions, or missing pieces.&lt;/li&gt;
&lt;li&gt;📆 &lt;strong&gt;Trace events through time with historical context&lt;/strong&gt;
Understand &lt;em&gt;how we got here&lt;/em&gt; by exploring the timeline of key events, decisions, and developments.&lt;/li&gt;
&lt;li&gt;🧠 &lt;strong&gt;Build your own opinion — not inherit someone else’s&lt;/strong&gt;
No algorithms pushing one narrative. You get the facts, the context, and the tools to think for yourself.&lt;/li&gt;
&lt;li&gt;🌍 &lt;strong&gt;Read articles from around the world — no language barrier&lt;/strong&gt;
NEWSARC automatically translates content into multiple languages, so you’re not limited by what’s written in your native tongue. The global conversation is open to &lt;em&gt;everyone&lt;/em&gt;.&lt;/li&gt;
&lt;li&gt;⚡ &lt;strong&gt;Get quick summaries and timelines with the help of AI&lt;/strong&gt;
Don’t have time to read it all? Let the AI generate concise summaries and timeline overviews so you can get up to speed in seconds — then dive deeper if you choose.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  🚧 A Work in Progress — with Big Dreams
&lt;/h3&gt;

&lt;p&gt;Let’s be clear: &lt;strong&gt;NEWSARC is still in its early days&lt;/strong&gt;.&lt;br&gt;&lt;br&gt;
 It’s raw, evolving, and far from perfect.&lt;/p&gt;

&lt;p&gt;Right now, you might notice a limited number of sources or some rough edges — but that’s part of the journey. We’re actively working on:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Adding &lt;strong&gt;more diverse and independent news sources&lt;/strong&gt;
&lt;/li&gt;
&lt;li&gt;Improving the user experience&lt;/li&gt;
&lt;li&gt;Making research faster, smarter, and more enjoyable&lt;/li&gt;
&lt;li&gt;Reducing bias through better curation and smart tooling&lt;/li&gt;
&lt;li&gt;Building features that help curious people dig deeper&lt;/li&gt;
&lt;li&gt;Build up the community to submit foreign news articels to be included in the timelines&lt;/li&gt;
&lt;li&gt;Make more accessibility features&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Think of this as an &lt;em&gt;open beta&lt;/em&gt;. We’re building in public — and your feedback is part of the roadmap.&lt;/p&gt;

&lt;h3&gt;
  
  
  ✨ Why It Matters
&lt;/h3&gt;

&lt;p&gt;In today’s world, information is everywhere. But understanding? That’s harder to come by.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;NEWSARC&lt;/strong&gt; exists for people who &lt;em&gt;don’t want to be told what to think&lt;/em&gt;. People who value curiosity, context, and critical thinking. People like you.&lt;/p&gt;

&lt;p&gt;We believe that democracy starts with understanding — and that understanding grows when we have access to many voices, not just one.&lt;/p&gt;

&lt;h3&gt;
  
  
  🌍 Come Take a Look
&lt;/h3&gt;

&lt;p&gt;This is your invitation.&lt;/p&gt;

&lt;p&gt;Explore NEWSARC. Play around. See how it feels to read a story from &lt;em&gt;more than one angle&lt;/em&gt;. If you like it, share it with someone who’s tired of seeing the world through a single window.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://newsarc.io" rel="noopener noreferrer"&gt;👉 Try it out at newsarc.io&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;We’re just getting started — and we’d love for you to be part of the journey.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fcdn-images-1.medium.com%2Fmax%2F1024%2F0%2Ao3p9UTgFxmm6-bkZ" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fcdn-images-1.medium.com%2Fmax%2F1024%2F0%2Ao3p9UTgFxmm6-bkZ" width="1024" height="683"&gt;&lt;/a&gt;&lt;br&gt;
&lt;em&gt;Photo by AbsolutVision on Unsplash&lt;/em&gt;&lt;/p&gt;

</description>
      <category>mindfulness</category>
      <category>news</category>
      <category>ai</category>
      <category>writing</category>
    </item>
    <item>
      <title>Mastering External API Usage in Angular Interceptors with x-api-key</title>
      <dc:creator>kbartsch</dc:creator>
      <pubDate>Tue, 03 Jun 2025 11:32:01 +0000</pubDate>
      <link>https://dev.to/mor3/mastering-external-api-usage-in-angular-interceptors-with-x-api-key-6gp</link>
      <guid>https://dev.to/mor3/mastering-external-api-usage-in-angular-interceptors-with-x-api-key-6gp</guid>
      <description>&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F8vgds10vmxxuvng7qccg.jpeg" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F8vgds10vmxxuvng7qccg.jpeg" width="800" height="318"&gt;&lt;/a&gt;&lt;br&gt;
&lt;em&gt;Image by T Hansen from Pixabay&lt;/em&gt;&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;&lt;strong&gt;Introduction&lt;/strong&gt; : In Angular development, managing API calls to multiple endpoints is common. Some endpoints may require an x-api-key for authentication, while others don’t. Instead of hardcoding headers in each service, Angular’s HttpInterceptor allows us to centralize request handling and apply API keys conditionally. Let’s explore how to implement this and the pros and cons of conditional key management. (For only readers Step 4is the important one)&lt;br&gt;&lt;br&gt;
&lt;strong&gt;Level: For everyone&lt;/strong&gt;&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;&lt;strong&gt;&lt;em&gt;Note:&lt;/em&gt;&lt;/strong&gt; &lt;em&gt;In this tutorial, we’ll build a simple Angular 19 application to fetch news articles using the&lt;/em&gt; &lt;a href="https://finlight.me/" rel="noopener noreferrer"&gt;&lt;strong&gt;&lt;em&gt;Finlight.me&lt;/em&gt;&lt;/strong&gt;&lt;/a&gt; &lt;strong&gt;&lt;em&gt;News API&lt;/em&gt;&lt;/strong&gt; &lt;em&gt;. While this guide uses Finlight.me to demonstrate managing an&lt;/em&gt; &lt;em&gt;x-api-key, you can easily adapt the approach for any API requiring custom headers. Our focus will be on creating an interceptor to handle the&lt;/em&gt; &lt;em&gt;x-api-key and applying it selectively to specific API requests.&lt;/em&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  Step 1: Set Up Your Angular Project
&lt;/h3&gt;

&lt;p&gt;First, create a new Angular project and install required dependencies. (NodeJS installation required)&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Create a new Angular project&lt;/strong&gt; :
&lt;/li&gt;
&lt;/ol&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;npx -p @angular/cli ng new angular-news-app 
cd angular-news-app
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Generate the Environments files&lt;/strong&gt; for your project:
&lt;/li&gt;
&lt;/ol&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;npx -p @angular/cli ng generate environments
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ol&gt;
&lt;li&gt;Open your project in your favorite editor (e.g., VS Code).&lt;/li&gt;
&lt;/ol&gt;

&lt;h3&gt;
  
  
  Step 2: Obtain the Finlight API Key
&lt;/h3&gt;

&lt;ol&gt;
&lt;li&gt;Go to &lt;a href="https://finlight.me" rel="noopener noreferrer"&gt;Finlight.me&lt;/a&gt; and create an account or use alternativ APIs.&lt;/li&gt;
&lt;li&gt;Navigate to the &lt;strong&gt;API Keys&lt;/strong&gt; section in the menu after logging in.&lt;/li&gt;
&lt;li&gt;Copy your free API key.&lt;/li&gt;
&lt;/ol&gt;

&lt;h3&gt;
  
  
  Step 3: Configure the Environment File
&lt;/h3&gt;

&lt;p&gt;Store your API key in Angular’s environment configuration file for secure and environment-specific management.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Open src/environments/environment.development.ts and add your API key:
&lt;/li&gt;
&lt;/ol&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;export const environment = {   
  production: false,   
  finlightApiKey: 'your-finlight-api-key-here' 
};
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ol&gt;
&lt;li&gt;Open src/environments/environment.ts and update the finlightApiKey for production:
&lt;/li&gt;
&lt;/ol&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;export const environment = {
  production: true,
  finlightApiKey: 'your-production-finlight-api-key-here'
};
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Step 4: Create the Interceptor
&lt;/h3&gt;

&lt;p&gt;We’ll create an interceptor to attach the x-api-key header only to Finlight’s API requests.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Generate the interceptor:
&lt;/li&gt;
&lt;/ol&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;ng generate interceptor interceptors/api-key
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ol&gt;
&lt;li&gt;Implement the interceptor in src/app/interceptors/api-key.interceptor.ts:
&lt;/li&gt;
&lt;/ol&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;import { Injectable } from '@angular/core';
import { HttpInterceptor, HttpRequest, HttpHandler, HttpEvent } from '@angular/common/http';
import { Observable } from 'rxjs';
import { environment } from '../../environments/environment';

@Injectable()
export class ApiKeyInterceptor implements HttpInterceptor {
  private apiKey = environment.finlightApiKey;

  intercept(req: HttpRequest&amp;lt;any&amp;gt;, next: HttpHandler): Observable&amp;lt;HttpEvent&amp;lt;any&amp;gt;&amp;gt; {
    const finlightUrlPattern = 'https://api.finlight.me'; // Match Finlight API endpoints

    if (req.url.includes(finlightUrlPattern)) {
      const secureReq = req.clone({
        headers: req.headers.set('x-api-key', this.apiKey)
      });
      return next.handle(secureReq);
    }

    // Forward requests to non-secure APIs without modifying
    return next.handle(req);
  }
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ol&gt;
&lt;li&gt;Register the interceptor in AppModule (src/app/app.module.ts):
&lt;/li&gt;
&lt;/ol&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;import { HTTP_INTERCEPTORS } from '@angular/common/http';
import { ApiKeyInterceptor } from './interceptors/api-key.interceptor';

@NgModule({
  providers: [
    { provide: HTTP_INTERCEPTORS, useClass: ApiKeyInterceptor, multi: true }
  ]
})
export class AppModule {}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Step 5: Create the News Service
&lt;/h3&gt;

&lt;p&gt;We’ll create a service to fetch data from the Finlight API.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Generate the service:
&lt;/li&gt;
&lt;/ol&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;ng generate service services/news
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ol&gt;
&lt;li&gt;Implement the service in src/app/services/news.service.ts:
&lt;/li&gt;
&lt;/ol&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;import { Injectable } from '@angular/core';
import { HttpClient } from '@angular/common/http';
import { Observable } from 'rxjs';

@Injectable({
  providedIn: 'root'
})
export class NewsService {
  private apiUrl = 'https://api.finlight.me/v1/articles';

  constructor(private http: HttpClient) {}

  // Fetch news from Finlight API
  getNews(): Observable&amp;lt;any&amp;gt; {
    return this.http.get(this.apiUrl);
  }
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Step 6: Build the News Component
&lt;/h3&gt;

&lt;p&gt;Create a component to display the news.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Generate the component:
&lt;/li&gt;
&lt;/ol&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;ng generate component components/news
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ol&gt;
&lt;li&gt;Update src/app/components/news/news.component.ts:
&lt;/li&gt;
&lt;/ol&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;import { Component, OnInit } from '@angular/core';
import { NewsService } from '../../services/news.service';

@Component({
  selector: 'app-news',
  templateUrl: './news.component.html',
  styleUrls: ['./news.component.css']
})
export class NewsComponent implements OnInit {
  newsArticles: any[] = [];

  constructor(private newsService: NewsService) {}

  ngOnInit(): void {
    this.newsService.getNews().subscribe({
      next: (data) =&amp;gt; (this.newsArticles = data.articles),
      error: (err) =&amp;gt; console.error('Error fetching news:', err)
    });
  }
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ol&gt;
&lt;li&gt;Update the component’s template in src/app/components/news/news.component.html:
&lt;/li&gt;
&lt;/ol&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;&amp;lt;div class="news-container"&amp;gt;
  &amp;lt;h1&amp;gt;Latest News&amp;lt;/h1&amp;gt;
  &amp;lt;div *ngFor="let article of newsArticles" class="news-article"&amp;gt;
    &amp;lt;h2&amp;gt;{{ article.title }}&amp;lt;/h2&amp;gt;
    &amp;lt;p&amp;gt;{{ article.publishDate}}&amp;lt;/p&amp;gt;
    &amp;lt;a [href]="article.link" target="_blank"&amp;gt;Read More&amp;lt;/a&amp;gt;
  &amp;lt;/div&amp;gt;
&amp;lt;/div&amp;gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ol&gt;
&lt;li&gt;Add some styles in src/app/components/news/news.component.css:
&lt;/li&gt;
&lt;/ol&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;.news-container {
  padding: 20px;
  font-family: Arial, sans-serif;
}
.news-article {
  border-bottom: 1px solid #ccc;
  margin-bottom: 20px;
  padding-bottom: 10px;
}
a {
  color: #007bff;
  text-decoration: none;
}
a:hover {
  text-decoration: underline;
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Step 7: Add the News Component to the App
&lt;/h3&gt;

&lt;ol&gt;
&lt;li&gt;Update src/app/app.component.html to include the NewsComponent:
&lt;/li&gt;
&lt;/ol&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;&amp;lt;app-news&amp;gt;&amp;lt;/app-news&amp;gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ol&gt;
&lt;li&gt;Serve the app in the terminal:
&lt;/li&gt;
&lt;/ol&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;npm start
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Step 8: Test the Application
&lt;/h3&gt;

&lt;ol&gt;
&lt;li&gt;Open your browser and navigate to &lt;a href="http://localhost:4200." rel="noopener noreferrer"&gt;http://localhost:4200.&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;The app will fetch and display the latest news from the Finlight API.&lt;/li&gt;
&lt;li&gt;Check the network requests in your browser’s developer tools to verify that the x-api-key is attached to requests to the secure API.&lt;/li&gt;
&lt;/ol&gt;

&lt;h3&gt;
  
  
  Final Thoughts
&lt;/h3&gt;

&lt;p&gt;In this tutorial, you’ve built a simple Angular app that fetches news articles using the Finlight API. By leveraging an Angular interceptor, you managed the x-api-key authentication in a clean, reusable way, applying it only to secure requests.&lt;/p&gt;

&lt;p&gt;This approach not only simplifies your code but also scales well for applications interacting with multiple APIs. Remember to keep your API keys secure and consider moving sensitive operations to the backend for production-grade security. There is also many things to learn and also to improve for example move the api url into an constant or use the new control flow from angular 17, but that is another story.&lt;/p&gt;

&lt;p&gt;Happy coding! 🚀&lt;/p&gt;

</description>
      <category>angular</category>
      <category>node</category>
      <category>security</category>
      <category>javascript</category>
    </item>
    <item>
      <title>Mastering package.json Versioning: Essential for Node.js Developers</title>
      <dc:creator>kbartsch</dc:creator>
      <pubDate>Tue, 20 May 2025 11:51:52 +0000</pubDate>
      <link>https://dev.to/mor3/mastering-packagejson-versioning-essential-for-nodejs-developers-5a8c</link>
      <guid>https://dev.to/mor3/mastering-packagejson-versioning-essential-for-nodejs-developers-5a8c</guid>
      <description>&lt;blockquote&gt;
&lt;p&gt;&lt;strong&gt;Introduction:&lt;/strong&gt; The package.json file is foundational for managing Node.js project dependencies. This configuration file, if managed properly, can be a powerful tool to ensure project stability and maintainability. One of its core features is version management, which hinges on a standard called Semantic Versioning (SemVer). Understanding this can significantly streamline your dependency management.&lt;br&gt;&lt;br&gt;
&lt;strong&gt;Level: Beginner&lt;/strong&gt;&lt;/p&gt;
&lt;/blockquote&gt;

&lt;h3&gt;
  
  
  Understanding Semantic Versioning (SemVer)
&lt;/h3&gt;

&lt;p&gt;Semantic Versioning is a versioning system that uses a three-part number: major.minor.patch. Each segment has a specific purpose:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;major: Incremented for incompatible API changes,&lt;/li&gt;
&lt;li&gt;minor: Incremented for new features that are backward compatible, and&lt;/li&gt;
&lt;li&gt;patch: Incremented for backward-compatible bug fixes.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Here’s an example to illustrate:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;"dependencies": {
  "express": "4.17.1"
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This line specifies that the project depends explicitly on version 4.17.1 of Express. It’s a precise version with no room for automatic updates.&lt;/p&gt;

&lt;h3&gt;
  
  
  Version Modifiers: Carets and Tildes
&lt;/h3&gt;

&lt;p&gt;The caret (^) and tilde (~) modifiers introduce flexibility in how updates are handled:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;^: This allows the installation of all future minor and patch versions without changing the major version. For instance:
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;"dependencies": {
  "lodash": "^4.17.15"
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This configuration permits updates to any 4.x.x version up to, but not including, 5.0.0.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;~: This is more restrictive, allowing only patch updates within a minor version:
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;"dependencies": {
  "moment": "~2.24.0"
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This limits updates to the 2.24.x range, offering a conservative approach to updates.&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;&lt;strong&gt;In short:&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Caret (&lt;/strong&gt;&lt;strong&gt;^):&lt;/strong&gt; Updates allowed within the current major version.&lt;br&gt;&lt;br&gt;
&lt;strong&gt;Example:&lt;/strong&gt; If you specify ^1.2.3, updates are permitted to any 1.x.x version up to but not including 2.0.0.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Tilde (&lt;/strong&gt;&lt;strong&gt;~):&lt;/strong&gt; Limits updates to the current minor version’s patch releases.&lt;br&gt;&lt;br&gt;
&lt;strong&gt;Example:&lt;/strong&gt; Specifying ~1.2.3 allows updates within the 1.2.x range, but not to 1.3.0 or higher.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;h3&gt;
  
  
  Advanced Versioning: Ranges and Wildcards
&lt;/h3&gt;

&lt;p&gt;For more specific needs, developers might use greater than (&amp;gt;) or less than (&amp;lt;) symbols, or even wildcards (*):&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&amp;gt; and &amp;lt;: Specify versions greater or less than a given version, as in:
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;"dependencies": {
  "react": "&amp;gt;16.13.1"
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This setup demands any version of React newer than 16.13.1.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;*: This wildcard allows any version:
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;"dependencies": {
  "vue": "*"
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This signifies readiness to accept any released version, which is generally not recommended for production environments.&lt;/p&gt;

&lt;h3&gt;
  
  
  Best Practices for Dependency Management
&lt;/h3&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Regular Reviews:&lt;/strong&gt; Actively monitor and review the project’s dependencies.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Utilize Lockfiles:&lt;/strong&gt; Make use of package-lock.json or yarn.lock to ensure consistency across installations.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Stay Updated:&lt;/strong&gt; Use tools like npm outdated to keep informed about newer versions and assess their impact before upgrading.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;By understanding package.json versioning, developers can better manage their project dependencies, avoiding potential conflicts and ensuring smoother operations. It’s essential to grasp each element of your dependency versioning to maintain a robust and stable architecture.&lt;/p&gt;

&lt;p&gt;Thank you for reading! I hope this quick guide helps you get a better grip on using version modifiers in your package.json. Happy coding and feel free to share!&lt;/p&gt;

&lt;p&gt;References: &lt;a href="https://docs.npmjs.com/cli/v8/configuring-npm/package-json#dependencies" rel="noopener noreferrer"&gt;NPM documentation&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fcdn-images-1.medium.com%2Fmax%2F1024%2F0%2AC_ksufeOCNNdLnAn" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fcdn-images-1.medium.com%2Fmax%2F1024%2F0%2AC_ksufeOCNNdLnAn" width="1024" height="683"&gt;&lt;/a&gt;&lt;br&gt;
&lt;em&gt;Photo by Markus Winkler on Unsplash&lt;/em&gt;&lt;/p&gt;

</description>
      <category>node</category>
      <category>softwaredevelopment</category>
      <category>javascript</category>
      <category>typescript</category>
    </item>
    <item>
      <title>Websockets vs. APIs: NewsAPI Features That Stands Out</title>
      <dc:creator>kbartsch</dc:creator>
      <pubDate>Tue, 13 May 2025 11:32:21 +0000</pubDate>
      <link>https://dev.to/mor3/websockets-vs-apis-newsapi-features-that-stands-out-20ic</link>
      <guid>https://dev.to/mor3/websockets-vs-apis-newsapi-features-that-stands-out-20ic</guid>
      <description>&lt;blockquote&gt;
&lt;p&gt;Introduction: Many news platforms deliver articles via &lt;strong&gt;GET APIs&lt;/strong&gt; , a standard method where you request data and get the latest articles back. But there’s a catch: this method often involves delays, and you might miss articles that are published just after your request or scraped later for past dates.&lt;br&gt;&lt;br&gt;
&lt;strong&gt;Level&lt;/strong&gt; : &lt;strong&gt;Beginner (2 min readtime)&lt;/strong&gt;&lt;/p&gt;
&lt;/blockquote&gt;

&lt;h3&gt;
  
  
  The Classic API — Good, but not Real-Time
&lt;/h3&gt;

&lt;p&gt;Most platforms rely on &lt;strong&gt;GET APIs&lt;/strong&gt; to deliver the latest content. You send a request, and the API returns the current articles. While this works, it comes with a delay, meaning you might miss a newly published article if it’s not included in the response.&lt;/p&gt;

&lt;p&gt;This approach is fine for users who don’t mind waiting for the next refresh. However, the major drawback is that you’re not getting content in &lt;strong&gt;real-time&lt;/strong&gt;.&lt;/p&gt;

&lt;h3&gt;
  
  
  Websockets — Real-Time, No Delays
&lt;/h3&gt;

&lt;p&gt;On the other hand, &lt;a href="https://finlight.me/" rel="noopener noreferrer"&gt;&lt;strong&gt;Finlight.me&lt;/strong&gt;&lt;/a&gt; &lt;strong&gt;(&lt;/strong&gt; I work with Finlight.me but there are also other apis that might have this — &lt;a href="https://techdailyfeed.com/10-best-news-apis-for-devs" rel="noopener noreferrer"&gt;https://techdailyfeed.com/10-best-news-apis-for-devs&lt;/a&gt;&lt;strong&gt;)&lt;/strong&gt; uses &lt;strong&gt;Websockets&lt;/strong&gt;. With Websockets, you get &lt;strong&gt;immediate updates&lt;/strong&gt; as soon as new articles are available — no need to keep making requests.&lt;/p&gt;

&lt;p&gt;Even if articles are published later, the Websocket pushes them to you right away. No more waiting or missing out on the latest news.&lt;/p&gt;

&lt;h3&gt;
  
  
  Why Websockets Make a Difference
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Real-Time Updates:&lt;/strong&gt; Websockets deliver news instantly, while APIs require you to manually request updates.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;No Missing Articles:&lt;/strong&gt; With Websockets, you get all new content, even if it’s older but newly published.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Effortless:&lt;/strong&gt; Websockets push content directly to you, so you don’t have to constantly refresh or check for updates.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Conclusion: The Edge of Real-Time
&lt;/h3&gt;

&lt;p&gt;While &lt;strong&gt;APIs&lt;/strong&gt; work for users who are okay with delays, &lt;a href="https://finlight.me/" rel="noopener noreferrer"&gt;&lt;strong&gt;Finlight.me&lt;/strong&gt;&lt;/a&gt; &lt;strong&gt;’s Websockets&lt;/strong&gt; offer a clear advantage for those who want &lt;strong&gt;real-time news&lt;/strong&gt; without the wait. It’s a simple but powerful improvement that ensures you never miss out on the latest articles.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Disclaimer:&lt;/strong&gt; I am currently working on news APIs and testing features for my own app. This post reflects my approach to evaluating news platforms and my experience working with &lt;a href="https://finlight.me/" rel="noopener noreferrer"&gt;&lt;strong&gt;Finlight.me&lt;/strong&gt;&lt;/a&gt;, where I provided feedback to help improve their service. I highly recommend testing their free tier to make up your own mind and see how it fits your needs, because there is no higher free tier on other platforms right now.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fcdn-images-1.medium.com%2Fmax%2F1024%2F0%2AKDpIJEzaj9abRg14" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fcdn-images-1.medium.com%2Fmax%2F1024%2F0%2AKDpIJEzaj9abRg14" width="1024" height="683"&gt;&lt;/a&gt;&lt;br&gt;
&lt;em&gt;Photo by Christopher Robin Ebbinghaus on Unsplash&lt;/em&gt;&lt;/p&gt;

</description>
      <category>websocket</category>
      <category>javascript</category>
      <category>news</category>
      <category>node</category>
    </item>
    <item>
      <title>Comparing News API Services: Finlight.me vs. Newsapi.org</title>
      <dc:creator>kbartsch</dc:creator>
      <pubDate>Wed, 07 May 2025 11:01:33 +0000</pubDate>
      <link>https://dev.to/mor3/comparing-news-api-services-finlightme-vs-newsapiorg-418d</link>
      <guid>https://dev.to/mor3/comparing-news-api-services-finlightme-vs-newsapiorg-418d</guid>
      <description>&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fcdn-images-1.medium.com%2Fmax%2F1024%2F0%2A9Mg-qSzZlePswHzl" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fcdn-images-1.medium.com%2Fmax%2F1024%2F0%2A9Mg-qSzZlePswHzl" width="1024" height="683"&gt;&lt;/a&gt;&lt;br&gt;
&lt;em&gt;Photo by Fujiphilm on Unsplash&lt;/em&gt;&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;I am currently experimenting with scrapers and news APIs as part of my programming journey. While brainstorming options, I stumbled upon two notable services: &lt;strong&gt;Finlight.me&lt;/strong&gt; and &lt;strong&gt;Newsapi.org&lt;/strong&gt;. Both offer intriguing possibilities, but they cater to slightly different needs. Here’s what I’ve discovered while exploring these platforms.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;h3&gt;
  
  
  Newsapi.org: The Veteran of News APIs
&lt;/h3&gt;

&lt;p&gt;Newsapi.org is a well-known name in the world of news aggregation APIs. It’s been around for a while, and its established features make it appealing. However, it does have some limitations, especially for someone like me who’s testing and learning.&lt;/p&gt;

&lt;h4&gt;
  
  
  Features:
&lt;/h4&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Article Search and Live Headlines&lt;/strong&gt; : Great for searching articles and getting live top headlines.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Access to Historical Data&lt;/strong&gt; : Articles up to a month old can be searched, though the free tier has delays.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;CORS Support&lt;/strong&gt; : Cross-Origin Resource Sharing (CORS) is enabled, which makes localhost development easier.&lt;/li&gt;
&lt;/ul&gt;

&lt;h4&gt;
  
  
  Limitations of the Free Tier:
&lt;/h4&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Request Cap&lt;/strong&gt; : The free tier only allows 100 requests per day — a bit restrictive when experimenting.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Article Delay&lt;/strong&gt; : Articles are delayed by 24 hours, which isn’t ideal for real-time applications.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;No SLA or Extra Requests&lt;/strong&gt; : There’s no Service Level Agreement (SLA), and you can’t request more in the free plan.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Pricing&lt;/strong&gt; : It becomes pricey if you need more extensive access.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Finlight.me: The New Challenger
&lt;/h3&gt;

&lt;p&gt;On the other hand, I found Finlight.me, a newer platform that’s specifically focused on financial news. What caught my attention was how much they emphasize user feedback and their plans to keep improving based on it. This approach feels refreshing for someone like me who’s experimenting and might have specific needs.&lt;/p&gt;

&lt;h4&gt;
  
  
  Features:
&lt;/h4&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Generous Free Tier&lt;/strong&gt; : Their free plan includes &lt;strong&gt;10,000 requests per month&lt;/strong&gt; , which is incredibly useful for testing.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Sentiment Analysis&lt;/strong&gt; : This built-in feature helps analyze the tone of financial news articles — something I find fascinating.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Rich Data Access&lt;/strong&gt; : Offers real-time and historical data, plus article content.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;CORS and Websockets&lt;/strong&gt; : Makes integrating with web apps and receiving real-time updates easier.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Future-Forward&lt;/strong&gt; : They’re planning advanced AI-driven sentiment analysis, which sounds exciting.&lt;/li&gt;
&lt;/ul&gt;

&lt;h4&gt;
  
  
  Why It Stands Out:
&lt;/h4&gt;

&lt;p&gt;Unlike Newsapi.org, Finlight.me actively seeks feedback to refine its offerings. This focus on financial news and adaptability makes it a compelling option for developers like me who value experimentation and responsiveness.&lt;/p&gt;

&lt;p&gt;One thing I particularly appreciate is how easy it is to contact the developers. Since it’s still a small platform, they’re very responsive. For instance, I suggested adding a news source that I was particularly interested in, and they quickly integrated it into their service for testing. It feels great to contribute to a platform with so much potential, especially when their free tier is already so fair and generous.&lt;/p&gt;

&lt;h3&gt;
  
  
  My Takeaways
&lt;/h3&gt;

&lt;p&gt;If you’re also exploring APIs for a project or learning, here’s what I’ve found:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Newsapi.org&lt;/strong&gt; is solid if you need a mature platform with broad news coverage, but its free tier is limited. No brain option.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Finlight.me&lt;/strong&gt; shines for financial news and offers much more flexibility for free, making it great for testing and learning. Option for builders and community interessted people.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Why Feedback Matters
&lt;/h3&gt;

&lt;p&gt;What I really like about Finlight.me is their openness to feedback. If you’re trying it out, you can share your thoughts to help them improve. It’s rare to find a service so willing to adapt based on user input that quick.&lt;/p&gt;

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

&lt;p&gt;For me, Finlight.me’s generous free tier and focus on financial news make it the more exciting choice, especially as I’m still experimenting and learning. Newsapi.org, on the other hand, is a safe and trusted option if you’re ready to commit to higher usage costs. Whether you’re brainstorming or building, there’s something to appreciate about both platforms.&lt;/p&gt;

</description>
      <category>startup</category>
      <category>news</category>
      <category>javascript</category>
      <category>development</category>
    </item>
    <item>
      <title>Understanding the SOLID Principles in Software Development</title>
      <dc:creator>kbartsch</dc:creator>
      <pubDate>Tue, 07 May 2024 10:02:45 +0000</pubDate>
      <link>https://dev.to/mor3/understanding-the-solid-principles-in-software-development-3e05</link>
      <guid>https://dev.to/mor3/understanding-the-solid-principles-in-software-development-3e05</guid>
      <description>&lt;blockquote&gt;
&lt;p&gt;&lt;strong&gt;Introduction&lt;/strong&gt; : In the realm of software development, adhering to best practices and design principles is paramount for creating robust, maintainable, and scalable codebases. One such set of principles that has gained widespread recognition is the SOLID principles. These principles serve as a guideline to facilitate the creation of software that is easy to understand, maintain, and extend. In this article, we will provide an overview of the SOLID principles, outlining each one’s significance and how they contribute to writing high-quality code.&lt;br&gt;&lt;br&gt;
&lt;strong&gt;Level: For everyone&lt;/strong&gt;&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;&lt;strong&gt;&lt;em&gt;Note:&lt;/em&gt;&lt;/strong&gt; &lt;em&gt;Keep in mind that this article is outlined as an overview, providing a brief introduction to each of the SOLID principles. If you’re interested in delving deeper into any specific principle, you can click on the corresponding links provided within the overview. Each link will redirect you to a detailed blog article dedicated to that particular SOLID principle.&lt;/em&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  SOLID Principles Overview:
&lt;/h3&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Single Responsibility Principle (SRP):&lt;/strong&gt; The Single Responsibility Principle advocates that a class should have only one reason to change, meaning it should have only one responsibility or job. By adhering to this principle, each class becomes focused and encapsulated, making it easier to understand, test, and maintain. — &lt;a href="https://medium.com/@kbartsch/solid-pattern-single-responsibility-principle-56b25c3b8678" rel="noopener noreferrer"&gt;&lt;strong&gt;Link to detailed article on SRP.&lt;/strong&gt;&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Open/Closed Principle (OCP):&lt;/strong&gt; The Open/Closed Principle emphasizes that software entities (classes, modules, functions, etc.) should be open for extension but closed for modification. This principle encourages developers to design systems in a way that new functionalities can be added without altering existing code, thus minimizing the risk of introducing bugs. — &lt;a href="https://medium.com/@kbartsch/solid-pattern-mastering-the-open-closed-principle-4dd6f3d98bc7" rel="noopener noreferrer"&gt;&lt;strong&gt;Link to detailed article on OCP.&lt;/strong&gt;&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Liskov Substitution Principle (LSP):&lt;/strong&gt; The Liskov Substitution Principle states that objects of a superclass should be replaceable with objects of its subclasses without affecting the correctness of the program. This principle ensures that derived classes adhere to the contracts established by their base classes, promoting polymorphism and enhancing code reusability. — &lt;strong&gt; &lt;/strong&gt; &lt;a href="https://medium.com/@kbartsch/solid-pattern-liskov-substitution-principle-69848d086dbc" rel="noopener noreferrer"&gt;&lt;strong&gt;Link to detailed article on LSP&lt;/strong&gt;&lt;/a&gt; &lt;strong&gt;.&lt;/strong&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Interface Segregation Principle (ISP):&lt;/strong&gt; The Interface Segregation Principle suggests that clients should not be forced to depend on interfaces they don’t use. Instead of implementing large, monolithic interfaces, it’s better to segregate them into smaller, specific ones, tailored to the needs of individual clients. This promotes loose coupling and ensures that classes remain focused on their intended functionality. — &lt;a href="https://medium.com/@kbartsch/solid-pattern-interface-segregation-principle-ba72c2634ea" rel="noopener noreferrer"&gt;&lt;strong&gt;Link to detailed article on ISP.&lt;/strong&gt;&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Dependency Inversion Principle (DIP):&lt;/strong&gt; The Dependency Inversion Principle advocates that high-level modules should not depend on low-level modules; both should depend on abstractions. Furthermore, abstractions should not depend on details; details should depend on abstractions. By decoupling components and relying on abstractions, code becomes more flexible, reusable, and easier to test. — &lt;a href="https://medium.com/@kbartsch/angular-solid-pattern-dependency-inversion-principle-8430efd5062b" rel="noopener noreferrer"&gt;&lt;strong&gt;Link to detailed article on DIP.&lt;/strong&gt;&lt;/a&gt;
&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;&lt;strong&gt;Conclusion:&lt;/strong&gt; The SOLID principles serve as foundational concepts in object-oriented design, guiding developers towards writing cleaner, more maintainable, and scalable code. By understanding and applying these principles, software engineers can build systems that are easier to extend, modify, and maintain, ultimately leading to higher-quality software products. Whether you’re a seasoned developer or just starting your journey, incorporating SOLID principles into your development practices will undoubtedly elevate your coding skills and contribute to the creation of better software solutions.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Outro: Thanks to you!&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;If you found this article and all other detail articles informative and helpful, feel free to share it with your fellow developers who might also benefit from learning about SOLID principles. Additionally, don’t forget to follow for more insightful content on software development best practices and stay updated on latest articles.&lt;/p&gt;

&lt;p&gt;Your support and engagement mean the world to me as it shows that the articles are interesting and helpful to continue. Together, let’s strive for excellence in software craftsmanship, continue knowledge-sharing in the vast landscape of IT and build a community committed to creating elegant, maintainable, and scalable software solutions.&lt;/p&gt;

&lt;p&gt;Thank you once again for your time. &lt;strong&gt;Happy coding!&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fcdn-images-1.medium.com%2Fmax%2F1024%2F0%2AymUARj7-HczyUaix" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fcdn-images-1.medium.com%2Fmax%2F1024%2F0%2AymUARj7-HczyUaix" width="1024" height="683"&gt;&lt;/a&gt;&lt;br&gt;
&lt;em&gt;Photo by Jason Goodman on Unsplash&lt;/em&gt;&lt;/p&gt;

</description>
      <category>architecture</category>
      <category>cleancode</category>
      <category>development</category>
      <category>coding</category>
    </item>
    <item>
      <title>SOLID Pattern — Liskov Substitution Principle</title>
      <dc:creator>kbartsch</dc:creator>
      <pubDate>Tue, 16 Apr 2024 10:01:44 +0000</pubDate>
      <link>https://dev.to/mor3/solid-pattern-liskov-substitution-principle-2g18</link>
      <guid>https://dev.to/mor3/solid-pattern-liskov-substitution-principle-2g18</guid>
      <description>&lt;h3&gt;
  
  
  SOLID Pattern — Liskov Substitution Principle
&lt;/h3&gt;

&lt;blockquote&gt;
&lt;p&gt;Welcome back to the last article on my SOLID pattern research by myself. As software engineers, we strive to write code that is not only functional but also maintainable, scalable, and robust. In object-oriented programming, adhering to solid principles is crucial for achieving these goals. One such principle is the Liskov Substitution Principle (LSP), named after Barbara Liskov, which states that objects of a superclass should be replaceable with objects of its subclasses without affecting the correctness of the program.&lt;br&gt;&lt;br&gt;
&lt;strong&gt;Level: None&lt;/strong&gt;&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;In TypeScript, a superset of JavaScript, we can leverage the static type system to enforce the Liskov Substitution Principle effectively. Let’s delve into some code examples to understand how this principle works and its implications.&lt;/p&gt;

&lt;p&gt;Consider the classic example of shapes, where we have a superclass Shape and subclasses Circle and Square. According to LSP, we should be able to substitute Circle and Square objects wherever Shape objects are expected.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;class Shape {
    area(): number {
        throw new Error("Method not implemented.");
    }
}

class Circle extends Shape {
    radius: number;

    constructor(radius: number) {
        super();
        this.radius = radius;
    }

    area(): number {
        return Math.PI * this.radius * this.radius;
    }
}

class Square extends Shape {
    sideLength: number;

    constructor(sideLength: number) {
        super();
        this.sideLength = sideLength;
    }

    area(): number {
        return this.sideLength * this.sideLength;
    }
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Now, let’s say we have a function calculateArea that expects an array of shapes and computes the total area:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;function calculateArea(shapes: Shape[]): number {
    let totalArea = 0;
    shapes.forEach(shape =&amp;gt; {
        totalArea += shape.area();
    });
    return totalArea;
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;By following LSP, we can confidently pass an array of Circle and Square objects to calculateArea, knowing that it will work as expected:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;const shapes: Shape[] = [new Circle(5), new Square(4)];
console.log(calculateArea(shapes)); // Output: 103.67 (approximately)
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;One advantage of adhering to LSP is the flexibility it provides. We can easily extend our system by adding new subclasses without modifying existing code. However, violating LSP can lead to unexpected behavior and bugs. For example, if we introduce a Triangle class that doesn't override the area method properly, it can break the behavior of calculateArea.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;class Triangle extends Shape {
    base: number;
    height: number;

    constructor(base: number, height: number) {
        super();
        this.base = base;
        this.height = height;
    }
}

const shapes: Shape[] = [new Circle(5), new Square(4), new Triangle(3, 6)];
console.log(calculateArea(shapes)); // Output: NaN (Not a Number)
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;Conclusion:&lt;/strong&gt; Liskov Substitution Principle plays a crucial role in designing robust and maintainable software systems. By adhering to this principle in TypeScript, we can write code that is not only type-safe but also flexible and easily extensible. Remember, honoring LSP leads to cleaner, more reliable code that stands the test of time.&lt;/p&gt;

&lt;p&gt;Hope the article was helpful. For the next and last story on this topic a summarized version of all patterns will be writen shortly. If you like what I do feel free to share and follow me! Have a great day!&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fcdn-images-1.medium.com%2Fmax%2F1024%2F0%2ACF1ooymL-BULmnbq" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fcdn-images-1.medium.com%2Fmax%2F1024%2F0%2ACF1ooymL-BULmnbq" width="1024" height="684"&gt;&lt;/a&gt;&lt;br&gt;
&lt;em&gt;Photo by Christina @ wocintechchat.com on Unsplash&lt;/em&gt;&lt;/p&gt;

</description>
      <category>softwaredevelopment</category>
      <category>typescript</category>
      <category>javascript</category>
      <category>learning</category>
    </item>
    <item>
      <title>SOLID Pattern — Interface Segregation Principle</title>
      <dc:creator>kbartsch</dc:creator>
      <pubDate>Tue, 09 Apr 2024 10:02:19 +0000</pubDate>
      <link>https://dev.to/mor3/solid-pattern-interface-segregation-principle-42jm</link>
      <guid>https://dev.to/mor3/solid-pattern-interface-segregation-principle-42jm</guid>
      <description>&lt;h3&gt;
  
  
  SOLID Pattern — Interface Segregation Principle
&lt;/h3&gt;

&lt;blockquote&gt;
&lt;p&gt;Greatings, today we are looking into a design pattern that will help us strive to create robust, maintainable, and scalable codebases. One such pattern in the realm of object-oriented design is the Interface Segregation Principle (ISP).&lt;br&gt;&lt;br&gt;
&lt;strong&gt;Level: Beginner&lt;/strong&gt;&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;At its core, ISP advocates for &lt;strong&gt;breaking down bulky interfaces into smaller, more focused ones, tailored to specific client requirements&lt;/strong&gt;. This approach not only &lt;strong&gt;promotes cohesion&lt;/strong&gt; but also &lt;strong&gt;prevents unnecessary dependencies&lt;/strong&gt; , paving the way for cleaner, more modular code.&lt;/p&gt;

&lt;p&gt;Let’s delve into some code examples to illustrate the prowess of ISP in TypeScript.&lt;/p&gt;

&lt;h4&gt;
  
  
  The Problem:
&lt;/h4&gt;

&lt;p&gt;Consider a scenario where we have a Printer interface that encompasses various functionalities:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;interface Printer {
  printDocument(): void;
  scanDocument(): void;
  faxDocument(): void;
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This Printer interface seems innocent at first glance, but it's a classic violation of ISP. What if we have a client who only needs printing capabilities? They would be forced to implement unnecessary methods like scanDocument and faxDocument, violating the principle of "Clients should not be forced to depend on methods they do not use."&lt;/p&gt;

&lt;h4&gt;
  
  
  The Solution:
&lt;/h4&gt;

&lt;p&gt;By adhering to ISP, we can refactor our interfaces to be more granular:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;interface Printer {
  printDocument(): void;
}

interface Scanner {
  scanDocument(): void;
}

interface FaxMachine {
  faxDocument(): void;
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;With this segregation, clients can now choose interfaces based on their specific needs. If a client only requires printing, they’ll depend solely on the Printer interface, reducing unnecessary coupling and potential headaches down the road.&lt;/p&gt;

&lt;h4&gt;
  
  
  &lt;strong&gt;Pros and Cons:&lt;/strong&gt;
&lt;/h4&gt;

&lt;h4&gt;
  
  
  💡Pros:
&lt;/h4&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Enhanced Modularity:&lt;/strong&gt; Segregated interfaces promote a modular design, allowing for easier maintenance and extensibility.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Reduced Coupling:&lt;/strong&gt; Clients depend only on what they need, mitigating the ripple effects of changes in unrelated functionalities.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Improved Testability:&lt;/strong&gt; Smaller interfaces facilitate targeted testing, leading to more robust test suites.&lt;/li&gt;
&lt;/ol&gt;

&lt;h4&gt;
  
  
  🚨Cons:
&lt;/h4&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Increased Interface Count:&lt;/strong&gt; Segregating interfaces might result in a proliferation of smaller interfaces, potentially cluttering the codebase if not managed properly.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Initial Overhead:&lt;/strong&gt; Refactoring existing code to adhere to ISP can be time-consuming initially, especially in larger projects.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;&lt;strong&gt;Conclusion:&lt;/strong&gt; In the ever-evolving landscape of software development, adherence to principles like ISP is paramount. In TypeScript, where strong typing is a boon, leveraging ISP can elevate your codebase to new heights of maintainability and flexibility. By embracing interface segregation, we pave the way for cleaner, more adaptable software systems that stand the test of time.&lt;/p&gt;

&lt;p&gt;Happy coding! Feel free to share and follow!&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fcdn-images-1.medium.com%2Fmax%2F1024%2F0%2A8NUtHiHG7ukx1KMd" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fcdn-images-1.medium.com%2Fmax%2F1024%2F0%2A8NUtHiHG7ukx1KMd" width="1024" height="1024"&gt;&lt;/a&gt;&lt;br&gt;
&lt;em&gt;Photo by True Agency on Unsplash&lt;/em&gt;&lt;/p&gt;

</description>
      <category>code</category>
      <category>softwaredevelopment</category>
      <category>cleancode</category>
      <category>typescript</category>
    </item>
    <item>
      <title>Why AI Alone Can’t Mentor Junior Devs</title>
      <dc:creator>kbartsch</dc:creator>
      <pubDate>Wed, 03 Apr 2024 10:01:57 +0000</pubDate>
      <link>https://dev.to/mor3/why-ai-alone-cant-mentor-junior-devs-3mkd</link>
      <guid>https://dev.to/mor3/why-ai-alone-cant-mentor-junior-devs-3mkd</guid>
      <description>&lt;blockquote&gt;
&lt;p&gt;Hello fellow coders, let’s dive into a different but broad world of software development, where junior devs are like the lone wolves adventurers armed with a map, a compass, and, lately, a shiny new AI companion. While it’s tempting to let the bots take the reins, there’s a danger in relying solely on artificial intelligence to guide our coding prodigies. Please note that this article is my opinion and sight on that topic.&lt;br&gt;&lt;br&gt;
&lt;strong&gt;Level: None&lt;/strong&gt;&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fcdn-images-1.medium.com%2Fmax%2F1024%2F0%2A3mkJJDEqFvPgdyAk" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fcdn-images-1.medium.com%2Fmax%2F1024%2F0%2A3mkJJDEqFvPgdyAk" width="1024" height="683"&gt;&lt;/a&gt;&lt;br&gt;
&lt;em&gt;Photo by Helena Lopes on Unsplash&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;Picture this: You hand over the responsibility of training junior devs to an AI, hoping for a seamless journey through the valleys of variables and the peaks of polymorphism. However, as any seasoned developer knows, the &lt;strong&gt;real coding expedition is more like a complex RPG than a stroll through a well-tailored tutorial and documentations&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;if we are looking for example at the code review, a crucial rite of passage for any developer from junior to seniors. &lt;strong&gt;AI tools can swiftly identify syntax errors, point out style violations, and even suggest potential optimizations&lt;/strong&gt;. But, my dear fellow devs, let’s not underestimate the importance of human experience in the realm of software craftsmanship. Now, don’t get me wrong, AI has come a long way now and can provide valuable insights but for now its still missing the human touch and knowledge of the surrounding elements.&lt;/p&gt;

&lt;p&gt;Imagine you’re facing a tricky bug, a real head-scratcher that has you contemplating a career change to goat herding. Here’s where the seasoned senior devs swoop in, capes flapping in the debugging breeze, armed with their mighty stack traces and knowledge of legacy code. Can AI truly grasp the intricacies of your project’s unique architecture and business logic? Can it identify future problems, risks or bugs related to architectural decision. At least not when this article was written but in the future this might be the case.&lt;/p&gt;

&lt;p&gt;Now, consider the training process. &lt;strong&gt;AI&lt;/strong&gt; , with its vast knowledge base, &lt;strong&gt;can provide theoretical insights, but it lacks the personal touch&lt;/strong&gt; of a mentorship forged through years of battles fought in the trenches of version control conflicts and merge hell. A &lt;strong&gt;real mentor in form of a senior developer can provide this personal touch&lt;/strong&gt; by &lt;strong&gt;showing insights in problems, experienced mistakes&lt;/strong&gt; and &lt;strong&gt;motivate&lt;/strong&gt; juniors &lt;strong&gt;to reach&lt;/strong&gt; thier &lt;strong&gt;business goals&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Conclusion:&lt;/strong&gt; AI can be a powerful ally, but it should complement, not replace, the human touch. After all, the best code is crafted with a dash of humanity, a sprinkle of AI magic, and a generous helping of experience by colleagues. Also keep in mind that AI should not and cannot replace the unique work environment atmosphere of individuals and adds value to the company a junior is working in.&lt;/p&gt;

&lt;p&gt;Hope you enjoyed my little articel! Feel free to like and share!&lt;/p&gt;

</description>
      <category>juniordeveloper</category>
      <category>mentorship</category>
      <category>cleancode</category>
      <category>softwaredevelopment</category>
    </item>
    <item>
      <title>SOLID Pattern — Single-Responsibility Principle</title>
      <dc:creator>kbartsch</dc:creator>
      <pubDate>Mon, 25 Mar 2024 11:02:24 +0000</pubDate>
      <link>https://dev.to/mor3/solid-pattern-single-responsibility-principle-5967</link>
      <guid>https://dev.to/mor3/solid-pattern-single-responsibility-principle-5967</guid>
      <description>&lt;h3&gt;
  
  
  SOLID Pattern — Single-Responsibility Principle
&lt;/h3&gt;

&lt;blockquote&gt;
&lt;p&gt;Greetings, today let’s dive into another SOLID pattern the Single-Responsibility Principle (SRP) with TypeScript. With this pattern we are able to improve issues like maintainability and scalability.&lt;br&gt;&lt;br&gt;
&lt;strong&gt;Level: Beginner&lt;/strong&gt;&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;The SRP, championed by the venerable Robert C. Martin, admonishes us to imbue our classes with a singular purpose, &lt;strong&gt;ensuring that each class is responsible for just one aspect of functionality&lt;/strong&gt; within our codebase. But how does this manifest in the TypeScript ecosystem? Let’s look at some code examples to see that it is not that big of a deal.&lt;/p&gt;

&lt;p&gt;Consider a hypothetical scenario where we’re crafting a rudimentary ship management system:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;// A class representing a ship
class Ship {
  private name: string;
  private crew: string[];

  constructor(name: string, crew: string[]) {
    this.name = name;
    this.crew = crew;
  }

  public sail(): void {
    console.log(`${this.name} sets sail with a crew of ${this.crew.join(', ')}.`);
    // Logic for setting sail
  }

  public loadCargo(cargo: string[]): void {
    console.log(`${this.name} loads cargo: ${cargo.join(', ')}.`);
    // Logic for loading cargo
  }
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Here, our Ship class seems okay at first glance, handling both sailing and cargo-loading duties. However, the SRP recommends us to separate concerns more distinctly. Let's follow this:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;// A class representing a ship
class Ship {
  private name: string;
  private crew: string[];

  constructor(name: string, crew: string[]) {
    this.name = name;
    this.crew = crew;
  }

  public sail(): void {
    console.log(`${this.name} sets sail with a crew of ${this.crew.join(', ')}.`);
    // Logic for setting sail
  }
}

// A separate class for managing cargo operations
class CargoManager {
  public loadCargo(ship: Ship, cargo: string[]): void {
    console.log(`${ship.name} loads cargo: ${cargo.join(', ')}.`);
    // Logic for loading cargo
  }
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;By untangling cargo-related operations into a distinct CargoManager class, we honor the SRP, ensuring that each class has a singular responsibility. This fosters code that's easier to comprehend, maintain, and extend—a improvement indeed!&lt;/p&gt;

&lt;p&gt;Let’s have a look and delve into the pros and cons of the Single-Responsibility Principle (SRP).&lt;/p&gt;

&lt;p&gt;💡 &lt;strong&gt;Pros:&lt;/strong&gt;&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Clarity and Maintainability:&lt;/strong&gt; By adhering to the SRP, we create classes that are focused and concise, making our codebase easier to understand and maintain. Each class encapsulates a single responsibility, reducing cognitive load and facilitating future modifications.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Scalability:&lt;/strong&gt; Separating concerns according to the SRP fosters modularization, enabling us to scale our codebase more efficiently. As our project grows, we can add new functionality without disturbing existing code, promoting code reuse and extensibility.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Testability:&lt;/strong&gt; With well-defined responsibilities, our classes become more testable. Unit testing becomes simpler, as we can isolate individual components and verify their behavior independently, leading to more robust and reliable code.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;🚨 &lt;strong&gt;Cons:&lt;/strong&gt;&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Increased Complexity:&lt;/strong&gt; Adhering strictly to the SRP can sometimes lead to an explosion of classes, introducing additional complexity and overhead. Managing a multitude of small classes may become cumbersome, especially in smaller projects or when dealing with simple functionalities.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Indirection and Abstraction:&lt;/strong&gt; Dividing responsibilities into separate classes may introduce indirection, making it harder to trace the flow of logic through our codebase. This abstraction layer can sometimes obscure the relationships between different components, requiring developers to invest extra effort in understanding the code.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Potential Over-Engineering:&lt;/strong&gt; In our zeal to uphold the SRP, we must guard against over-engineering. Splitting responsibilities too finely can lead to unnecessary abstraction and code bloat, complicating the codebase without providing significant benefits in terms of clarity or maintainability.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;&lt;strong&gt;Conclusion:&lt;/strong&gt; Following the Single Responsibility Principle (SRP) makes our code easier to maintain, but it also means we might need more classes and extra steps, which can add some complexity. In short we must strike a balance between clarity and pragmatism.&lt;/p&gt;

&lt;p&gt;Hope you enjoyed this little articel! Feel free to follow and sharing my library of knowledge, that’s been created here.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fcdn-images-1.medium.com%2Fmax%2F1024%2F0%2AFBeAKHBBVvX_SPHx" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fcdn-images-1.medium.com%2Fmax%2F1024%2F0%2AFBeAKHBBVvX_SPHx" width="1024" height="683"&gt;&lt;/a&gt;&lt;br&gt;
&lt;em&gt;Photo by Sigmund on Unsplash&lt;/em&gt;&lt;/p&gt;

</description>
      <category>softwaredevelopment</category>
      <category>patterns</category>
      <category>cleancode</category>
      <category>javascript</category>
    </item>
  </channel>
</rss>
