An Explaining Variable is a code-level pattern which reduces the need for code comments, making your software a little more self-documenting. Here we have a function with some non-obvious business logic, with a comment to explain what’s going on: before.js function determineShippingSpeed(shippingRoute, shippingMethod) { // if the shipping route is very short, or it’s by air if( shippingRoute.distance < 20 || [BY_AIR,BY_AIR_EXPRESS].includes(shippingMethod) ){ return SAME_DAY; } // ... } A...| Blogs on Pete Hodgson
Learn how to overcome Xcode's slow test feedback and enhance your TDD workflow. Follow our steps to achieve faster test feedback, dropping from 47s to 1.6s.| Quality Coding
Every developer integrates their work into mainline at least every day.| martinfowler.com