83% wp-lazy-load-images

Code Review | WP jQuery Lazy Load

WordPress plugin WP jQuery Lazy Load scored83%from 54 tests.

About plugin

  • Plugin page: wp-lazy-load-images
  • Plugin version: v4.0...
  • PHP version: 7.4.16
  • WordPress version: 6.3.1
  • First release: Feb 10, 2016
  • Latest release: Dec 20, 2021
  • Number of updates: 7
  • Update frequency: every 305.9 days
  • Top authors: shaibi (100%)

Code review

54 tests

User reviews

3 reviews

Install metrics

20+ active /3,421 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
Install script ran successfully

Server metrics [RAM: ▲0.01MB] [CPU: ▼1.46ms] Passed 4 tests

Server-side resources used by WP jQuery Lazy Load
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0239.73 ▼2.81
Dashboard /wp-admin3.32 ▲0.0247.18 ▲1.40
Posts /wp-admin/edit.php3.37 ▲0.0147.16 ▲3.02
Add New Post /wp-admin/post-new.php5.90 ▲0.0189.76 ▼0.91
Media Library /wp-admin/upload.php3.25 ▲0.0132.43 ▼3.53

Server storage [IO: ▲0.01MB] [DB: ▲0.00MB] Passed 3 tests

Input-output and database impact of this plugin
There were no storage issued detected upon installing this plugin
Filesystem: 4 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-comments
widget_recent-posts
theysaidso_admin_options
can_compress_scripts
db_upgraded
widget_theysaidso_widget

Browser metrics Passed 4 tests

This is an overview of browser requirements for WP jQuery Lazy Load
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,883 ▲12613.62 ▼0.596.45 ▲4.2044.29 ▼7.66
Dashboard /wp-admin2,206 ▲214.88 ▼0.19111.09 ▲5.4138.85 ▼3.09
Posts /wp-admin/edit.php2,089 ▲32.05 ▲0.0834.93 ▼1.2431.19 ▼1.61
Add New Post /wp-admin/post-new.php1,536 ▲2223.35 ▲5.70661.46 ▲3.1456.01 ▲3.06
Media Library /wp-admin/upload.php1,385 ▼34.22 ▼0.0594.56 ▼11.0742.97 ▼1.46

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
These items require your attention
  • Zombie WordPress options detected upon uninstall: 6 options
    • db_upgraded
    • widget_recent-comments
    • widget_theysaidso_widget
    • can_compress_scripts
    • widget_recent-posts
    • theysaidso_admin_options

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Even though no errors were found, this is by no means an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
The following issues need your attention
  • 1× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/wp-lazy-load-images/jq_img_lazy_load.php:15

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
No browser errors were detected

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
Please fix the following attributes:
  • Requires at least: Version format is invalid
You can take inspiration from this readme.txt

wp-lazy-load-images/jq_img_lazy_load.php 85% from 13 tests

The entry point to "WP jQuery Lazy Load" version v4.0... is a PHP file that has certain tags in its header comment area
Please take the time to fix the following:
  • Version: The version number should only use digits and periods (ex. "1.0.3" instead of "v4.0...")
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("wp-lazy-load-images.php" instead of "jq_img_lazy_load.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short review of files and their extensions; it is not recommended to include executable files
There were no executable files found in this plugin217 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript13934169
PHP1141548

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.16
Average class complexity4.00
▷ Minimum class complexity4.00
▷ Maximum class complexity4.00
Average method complexity1.50
▷ Minimum method complexity1.00
▷ Maximum method complexity2.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods6
▷ Static methods00.00%
▷ Public methods6100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
There were not PNG files found in your plugin