84% lazy-load-for-comments

Code Review | Lazy Load for Comments

WordPress plugin Lazy Load for Comments scored 84% from 54 tests.

About plugin

  • Plugin page: lazy-load-for-com...
  • Plugin version: 1.0.10
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-6.1
  • WordPress version: 6.3.1
  • First release: Jul 21, 2016
  • Latest release: Oct 28, 2022
  • Number of updates: 32
  • Update frequency: every 71.4 days
  • Top authors: joelcj91 (100%)

Code review

54 tests

User reviews

27 reviews

Install metrics

4,000+ active / 194,899 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
Install script ran successfully

Server metrics [RAM: ▲0.07MB] [CPU: ▲1.33ms] Passed 4 tests

Server-side resources used by Lazy Load for Comments
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.53 ▲0.0740.12 ▼0.45
Dashboard /wp-admin3.37 ▲0.0755.48 ▲4.77
Posts /wp-admin/edit.php3.48 ▲0.1346.08 ▼0.10
Add New Post /wp-admin/post-new.php5.95 ▲0.06105.84 ▲7.64
Media Library /wp-admin/upload.php3.29 ▲0.0638.80 ▲1.11

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

Filesystem and database footprint
This plugin was installed successfully
Filesystem: 23 new files
Database: no new tables, 6 new options
New WordPress options
theysaidso_admin_options
widget_theysaidso_widget
can_compress_scripts
widget_recent-posts
widget_recent-comments
db_upgraded

Browser metrics Passed 4 tests

This is an overview of browser requirements for Lazy Load for Comments
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,825 ▲9014.52 ▲0.152.01 ▲0.2139.63 ▼4.46
Dashboard /wp-admin2,206 ▲184.85 ▼0.0598.85 ▼6.0837.93 ▼4.16
Posts /wp-admin/edit.php2,089 ▼32.00 ▼0.0235.79 ▼3.3934.54 ▲2.56
Add New Post /wp-admin/post-new.php1,534 ▼023.16 ▲0.13607.90 ▼10.7547.43 ▼14.42
Media Library /wp-admin/upload.php1,388 ▼04.24 ▲0.0199.88 ▼9.0247.80 ▲3.72

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
Please fix the following items
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • widget_theysaidso_widget
    • widget_recent-posts
    • can_compress_scripts
    • widget_recent-comments
    • theysaidso_admin_options
    • db_upgraded

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
The smoke test was a success, however most plugin functionality was not tested

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
  • 9× PHP files perform the task of outputting text when accessed with GET requests:
    • > /wp-content/plugins/lazy-load-for-comments/public/llc-comments.php
    • > /wp-content/plugins/lazy-load-for-comments/admin/class-llc-admin.php
    • > /wp-content/plugins/lazy-load-for-comments/includes/class-lazy-load-comments.php
    • > /wp-content/plugins/lazy-load-for-comments/includes/class-llc-compatibility.php
    • > /wp-content/plugins/lazy-load-for-comments/public/class-llc-public.php
    • > /wp-content/plugins/lazy-load-for-comments/lazy-load-for-comments.php
    • > /wp-content/plugins/lazy-load-for-comments/includes/class-llc-i18n.php
    • > /wp-content/plugins/lazy-load-for-comments/includes/class-llc-loader.php
    • > /wp-content/plugins/lazy-load-for-comments/uninstall.php

User-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
There were no browser issues found

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

You should put a lot of thought into formatting readme.txt as it is used by WordPress.org to prepare the public listing of your plugin
6 plugin tags: lazy comments, comments, lazyload wordpress comments, lazyload comments, conditional comments...

lazy-load-for-comments/lazy-load-for-comments.php Passed 13 tests

The entry point to "Lazy Load for Comments" version 1.0.10 is a PHP file that has certain tags in its header comment area
132 characters long description:
Lazy Load default WordPress comments. Load comments only after user clicking on a button or scrolling down. It saves page load time.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
Success! There were no dangerous files found in this plugin381 lines of code in 14 files:
LanguageFilesBlank linesComment linesLines of code
PHP1097524293
JavaScript4108088

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.40
Average class complexity6.17
▷ Minimum class complexity1.00
▷ Maximum class complexity26.00
Average method complexity2.24
▷ Minimum method complexity1.00
▷ Maximum method complexity11.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes6
▷ Abstract classes00.00%
▷ Concrete classes6100.00%
▷ Final classes00.00%
Methods25
▷ Static methods00.00%
▷ Public methods1664.00%
▷ Protected methods00.00%
▷ Private methods936.00%
Functions1
▷ Named functions1100.00%
▷ Anonymous functions00.00%
Constants1
▷ Global constants1100.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
PNG images were not found in this plugin