gjtorikian/html-proofer — pull request #112 by akoeplinger (2014-09-11 20:11:27+00:00)
Title: Cache the Uri parser instance in Checkable, results in a 14x performance increase

The parts getter in Checkable is called **very** often, which means caching the Uri parser instance instead of recreating it on every call massively improves performance.

Here's a small timing of a site with ~30 files (external checks ignored):

|before|after|
|------------|------------------|
|**real 0m25.782s**|**real 0m1.810s**|
|user 0m25.377s|user 0m1.681s|
|sys 0m0.384s|sys 0m0.122s|