Image_Functions_Usage_Check
: Would warn about any direct output of img tags in PHP code and templates
#468
Labels
Image_Functions_Usage_Check
: Would warn about any direct output of img tags in PHP code and templates
#468
As suggested by @felixarntz in #443, those should use
wp_get_attachment_image()
etc. instead, which comes with performance benefits. The exception is img tags which aren't for attachments. For such manual img tags, the check could trigger a warning if the wp_get_loading_optimization_attributes() is not used as part of generating the output.We could probably use the same/opposite approach as core does to to find images without the core image class (in a runtime check)
The text was updated successfully, but these errors were encountered: