-
Pooling Resources With The Object Pool Pattern
I find the Object Pool pattern extremely useful. For starters, I can easily count how many instances of a class instantiated or replace a specific instance without worrying about which objects might still hold a reference to the old version.
Read more... -
Visiting The Visitor Pattern In Javascript
The visitor pattern allows you to separate functionality from the object it functions on. We can often make use of this pattern when working with components and composites.
Read more... -
Jquery Type And Custom Types
jQuery uses a clever bit of code to extract the type of a parameter.
Read more... -
Profile Jquery Selectors
For performance reasons, I wanted to quickly audit what selectors a site used with jQuery. Using the script below, I evaluated the $profile object to get an idea of how often Sizzle was engaged and for what types of elements. It really helps to add this before
Read more...document.ready
(when all the Sizzle craziness starts) but after jQuery and your plugins load. -
Adding Dynatrace Markers Dynamically
While using dynaTrace with our app, we needed a way to inject markers dynamically. We also wanted the profiling code to have a minimal footprint, not run in production, give us the most accurate measurements, and not interact with production code.
Read more...