Apply essential clean code principles, such as DRY, KISS, Law of Demeter, and SOLID. This course helps reinforce best practices through practical implementation and real-world examples in Ruby.
Overview
Syllabus
- Unit 1: Applying Clean Code Principles with Ruby: Embracing the DRY Principle
- Applying DRY: Refactoring Code to Extract Methods
- Variable Extraction and PI Centralization Task
- Replace Temporary Variables with Query Methods in Ruby
- Unit 2: Applying Clean Code Principles with Ruby: Embracing the KISS Principle
- Applying the KISS Principle to Simplify Code
- Refactoring Leap Year Logic Using KISS Principle
- Simplifying Palindrome Checker Using the KISS Principle
- Unit 3: Applying Clean Code Principles with Ruby: Understanding the Law of Demeter
- Refactoring for the Law of Demeter in Ruby
- Refactoring for Law of Demeter Compliance
- Unit 4: Applying Clean Code Principles with Ruby: Understanding the SOLID Principles
- Refactoring for Single Responsibility Principle in Ruby
- Redesigning Code for Open/Closed Principle in Ruby
- Implementing Interface Segregation Principle in Ruby
- Implementing Dependency Inversion Principle in a Printer System