
Identify and eliminate 20 code smells to design solid software, learning why they occur, how they violate solid principles, and how to iteratively improve your codebase.
Explore the four foundations of good software design: information hiding, encapsulation, abstraction, and polymorphism, linked to solid principles for decoupled, maintainable code.
Choose deep modules over shallow ones by offering a simple interface that delivers more functionality, reducing coupling and easing maintenance through information hiding.
Apply the single responsibility principle to give each class one reason to change. Expose interfaces and depend on interfaces, not implementation, to reduce coupling in inventory, shipment, and invoice management.
Apply the open/close principle to software design by creating a stable data store interface and extending functionality with new modules through polymorphism, instead of modifying existing code.
Demonstrate the Liskov substitution principle by showing that a subclass must not contradict a superclass, and advocate composition to let birds fly and fish swim without breaking the application.
Apply the interface segregation principle by splitting large interfaces into smaller ones so classes implement only needed methods. Avoid empty implementations and clarify expectations for inventory, shipment, and invoice managers.
Explore the dependency inversion principle by showing high-level and low-level modules depend on abstractions via a data store interface, enabling swapping file store for HTTP store without changing data display.
Navigate the code base to explore code smells, compare master and solutions branches, and use the IDE to review commits and evolve solutions with peer feedback.
Explore why repeated switches are a code smell and how encapsulating conditional logic or using polymorphism can eliminate duplicated conditionals, reduce leaks, and simplify maintenance.
Examine the repeated switches code smell in a calculator example, where separate switch statements for executing and printing operations cause maintenance headaches as new operations are added.
Refactor a calculator by introducing an operation interface and a factory function to replace the switch with encapsulation and the open-closed principle, enabling maintainable, extensible operations and clear to-string representations.
Identify how primitive obsession causes poor encapsulation and duplicated knowledge. Fix it by creating custom types like currency or phone to contain domain logic and validation, avoiding type explosion.
Illustrates primitive obsession in a customer class that validates email and phone with regex, revealing logic leakage and duplication across entities, with encapsulation in the next video.
Refactor the customer constructor by introducing a customer raw data object and separate email and phone classes, encapsulating validation to improve modularity and prevent parameter mishaps.
Explore why loops can signal code smells, hide encapsulation, and add boilerplate, then learn to replace them with pipeline structures like map, filter, and reduce.
This loop-focused example shows a function converting records to CSV by building headers from keys and lines from values, including undefined handling, highlighting nested loops, verbosity, and duplication removal.
Transform loops into map and join pipelines, derive headers from object keys, and handle empty records with an or operator, reducing boilerplate and producing cleaner csv output.
Identify the long parameter list code smell and replace flag parameters by splitting the method and using polymorphism to drive runtime behavior, improving maintainability and reducing order sensitivity.
Explore the long parameter list code smell in a constructor, highlighting optional vs. required parameters, risks of misusing id fields, and refactoring strategies to improve type safety.
Learn how to reduce a long parameter list by deriving fields from a customer interface and replacing a boolean flag with polymorphism using standard and premium orders.
Identify knowledge duplication across the codebase, understand its harm when the same unit of knowledge repeats, and learn to extract it into helper functions or classes while preserving SOLID principles.
Demonstrates knowledge duplication in code by showing two functions that read CSV data, read properties, and parse customers, causing repeated setup before sending emails or displaying customers.
Refactor a flawed loop and condition to eliminate knowledge duplication by filtering customers, printing emails, and encapsulating data handling in a unified module.
Identify uninformative comments as a code smell that pollutes readability and maintenance. Write good comments that capture reasoning and intended usage, remove duplicates, and keep documentation valid as code evolves.
Evaluate uninformative comments in a CSV-to-customers example and illustrate transforming a CSV file into an array of customer objects while emphasizing why comments should be meaningful.
Remove uninformative comments and clarify code by adding precise inline notes and top-level function documentation, using JSDoc to describe parameters, file paths, and return shapes.
Shotgun surgery forces changes across multiple places due to high coupling, including semantic coupling; add abstraction and encapsulation to reduce dependencies.
Examine the shotgun surgery code smell and coupling to internal data and formats, then learn to hide data structures behind a private interface that applies discounts to price.
Apply encapsulation and decoupling to reduce shotgun surgery by turning raw data into cohesive customer and discount classes, using getters, setters, and dedicated methods to compute address and discounts.
BRING YOUR SOFTWARE DEVELOPMENT SKILLS TO THE NEXT LEVEL!
Learn the SOLID principles and how they can improve the design of your code
Learn 20 code smells and anti-patterns against best software design practices
Learn how to write code that is easy to maintain, extend, and change
Explore practical examples in a variety of applications
Benefit from deep dives and detailed discussions around best practices in the software engineering industry
A STEP-BY-STEP COURSE, FOR BEGINNERS AND ADVANCED DEVELOPERS:
This course is thought for both those who are starting their software development carriers and want to learn how to design SOLID code from the start, as well as for those who are in the industry for several years and want to improve their coding!
6 hours of high-quality, straight-to-the-point videos
Self-paced course: take as much time as you need to complete the course
Lifetime access: access does not expire. Ever!
30-day money-back guarantee: try the course without risks. No questions asked
Certificate of completion: receive a solid proof of completion and differentiate yourself
WHY THIS COURSE?
Focus on the fundamental principles of software design: Information Hiding, Encapsulation, Abstraction, and Polymorphism.
Detailed and easy to follow discussion on 5 SOLID principles: Single Responsibility principle, Open-Close principle, Liskov Substitution principle, Interface Segregation principle, and Dependency Inversion principle.
20 code smells distilled and thoroughly explained: learn many different ways we can fix our code, making it more robust and easier to work with.
At the end of this course, you will have acquired not only knowledge about the principles of great software development, but also practical insight into how to reason about the design of your system and how to improve it.
WHY LEARN SOLID PRINCIPLES AND CODE SMELLS?
Excelling in software development goes far beyond writing code. The code we write must not only achieve its intended functionality, but it must also be easy to maintain, extend, and change. When our code is not well designed, it starts to show several symptoms called code smells. It is crucial to be fully aware of them to immediately address the underlying causes when we come across bad code.
To develop this awareness, this course discusses the most important principles for designing and developing systems that comply with programming best practices. The contents are based on my learnings from multiple years of coding experience, as well as on several books and resources from seasoned developers in the industry.
I’m looking forward to taking this journey with you!
Course thumbnail credits: macrovector - freepik