-
Recent Posts
Recent Comments
- Alper Sunar on Presenters, Use Code Snippets for Live Coding
- Carlos Ribas on Presenters, Use Code Snippets for Live Coding
- rsanchez1 on Presenters, Use Code Snippets for Live Coding
- John Teague on Presenters, Use Code Snippets for Live Coding
- Carlos Ribas on Presenters, Use Code Snippets for Live Coding
Archives
- May 2013
- March 2013
- January 2013
- November 2012
- June 2012
- May 2012
- March 2012
- February 2012
- December 2011
- November 2011
- October 2011
- August 2011
- July 2011
- June 2011
- May 2011
- March 2011
- December 2010
- August 2010
- June 2010
- March 2010
- February 2010
- January 2010
- November 2009
- October 2009
- August 2009
- June 2009
- October 2007
Categories
Meta
Category Archives: refactoring
A Guest Appearance On Tekpub’s Knockout.js Series
Tekpub release their series on Knockout.js recently and I was fortunate enough to make a guest appearance! Now I know you’re thinking “why would Derick make an appearance in a Knockout series?!” But don’t worry – I’m not there to … Continue reading
Improve your LINQ with .Any()
LINQ’s .Any() method is under-utilized, given the benefits it brings in making your code briefer, clearer, and more efficient. LINQ in general improves the expressiveness of your collection-manipulating code by using declarative statements instead of imperative foreach loops; .Any() is … Continue reading
Running JavaScript… With Sneakers!
Code-review time. I haven’t written significant JavaScript in forevs, but I hit upon a use case well suited to it, had a blast coding it up, and am confident that I’ll be completely mystified by it three months from now. … Continue reading
Also posted in arduino, JavaScript
5 Comments
Rebuilding My Backbone.js Plugins With Modules, SRP and More
In the last few weeks, I’ve rebuilt and refactored a large amount of JavaScript code in both my Backbone.ModelBinding and Backbone.Memento plugins. In the process, I re-learned several object oriented design principles and how they apply to JavaScript. I also … Continue reading
Legacy Operating Systems and Legacy Languages: If it ain’t broke, it still needs fixing
In my travels I’ve encountered systems chugging happily along on outdated, discontinued, unsupported technology stacks. Apps written in VB6, FoxPro, Classic ASP, still running without a hitch because the kinks had been shaken out years ago… Software users delicately avoiding … Continue reading
An Object Lesson in Binary Compatibility
A riddle for you, friends: When is changing a method from return void to return Something a breaking change? If you already know the answer, then why hadn’t you told me? Could’ve saved me a fair bit of embarrassment. Ah … Continue reading
Also posted in Open-Source Software
4 Comments
Good Refactoring / Patterns For Simple UI Logic?
I’ve got a chunk of C# that sits inside of a very simple form. The form downloads an update from a web page – one of two possible downloads, based on which one is available – and shows a message … Continue reading
A Less Ugly Switch Statement For C#
I know switch statements are considered “evil” because they are very procedural code, they violate the Open-Closed Principle, etc etc. But every now and then I don’t see a need to do anything more than a switch statement because the … Continue reading
A Refactoring: Explicit Modeling And Reducing Duplication
A coworker showed me a method that had a series of guard clauses at the top and a series of sequential steps that had to be processed after that. All of the guard clauses and sequential steps were executed the … Continue reading
"Refactoring" Notes
I’m not going to bother with a review of Martin Fowler‘s Refactoring: Improving the Design of Existing Code. It’s good enough that its catalog, available in expanded form online, now provides the definitive vocabulary shared by dozens of refactoring tools … Continue reading
