useref HTML Build Block Parser

JSON →
library 1.4.4 ·javascript
verified May 27, 2026

useref is a JavaScript library designed to parse HTML files and replace special "build blocks" with optimized references. Extracted from the `grunt-useref` plugin, it provides a standalone utility for integrating into web build processes. The current stable version is 1.4.4, with releases appearing to be on an as-needed basis, focusing on stability and bug fixes as indicated by the versioning. Its primary differentiator is its ability to identify and process `<!-- build:<type> <path> -->...<!-- endbuild -->` comments, consolidating multiple script or link tags into a single optimized reference, and supporting custom block types for advanced processing. It also preserves IE conditional comments. This functionality is crucial for web performance optimization workflows where assets are concatenated and minified.

total hits 11
actors 5 distinct systems
last hit 8d ago Script
GPTBot
5
Script
1
Search engines
2

top countries 🇺🇸 United States · 🇨🇦 Canada · 🇩🇪 Germany