84% navthemes-lazy-load

Code Review | NavThems Lazy Load

WordPress plugin NavThems Lazy Load scored 84% from 54 tests.

About plugin

  • Plugin page: navthemes-lazy-load
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.8-5.1.1
  • WordPress version: 6.3.1
  • First release: May 3, 2019
  • Latest release: May 3, 2019
  • Number of updates: 2
  • Update frequency: every 1.0 days
  • Top authors: navthemes (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 516 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
Installer ran successfully

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

Analyzing server-side resources used by NavThems Lazy Load
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0139.97 ▼1.76
Dashboard /wp-admin3.31 ▲0.0145.37 ▼6.74
Posts /wp-admin/edit.php3.36 ▲0.0150.34 ▲1.97
Add New Post /wp-admin/post-new.php5.90 ▲0.0196.46 ▲1.44
Media Library /wp-admin/upload.php3.24 ▲0.0132.65 ▼3.28

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

Input-output and database impact of this plugin
The plugin installed successfully
Filesystem: 5 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-posts
widget_recent-comments
db_upgraded
can_compress_scripts
widget_theysaidso_widget
theysaidso_admin_options

Browser metrics Passed 4 tests

This is an overview of browser requirements for NavThems Lazy Load
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,827 ▲9214.27 ▼0.343.58 ▲1.4040.61 ▼8.60
Dashboard /wp-admin2,206 ▲184.86 ▼0.0299.88 ▼19.0539.06 ▼9.70
Posts /wp-admin/edit.php2,092 ▲32.00 ▼0.0240.99 ▲5.8636.32 ▼0.77
Add New Post /wp-admin/post-new.php1,534 ▲123.41 ▲0.02601.88 ▼59.0454.90 ▼0.58
Media Library /wp-admin/upload.php1,388 ▼34.24 ▲0.0696.16 ▼3.1443.88 ▲0.25

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
Please fix the following items
  • This plugin does not fully uninstall, leaving 6 options in the database
    • db_upgraded
    • can_compress_scripts
    • theysaidso_admin_options
    • widget_recent-posts
    • widget_theysaidso_widget
    • widget_recent-comments

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Good news, no errors were detected

SRP 50% from 2 tests

🔹 Tests weight: 20 | A shallow check of the single-responsibility principle; PHP files should perform no action - including output of placeholder text - and trigger no errors when accessed directly
Almost there! Just fix the following items
  • 1× PHP files output non-empty strings when accessed directly via GET requests:
    • > /wp-content/plugins/navthemes-lazy-load/navthemes-lazyload.php

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Everything seems fine on the user side

Optimizations

Plugin configuration 93% from 29 tests

readme.txt Passed 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
4 plugin tags: lazyload, page insight, lazy loading, speed

navthemes-lazy-load/navthemes-lazyload.php 85% from 13 tests

This is the main PHP file of "NavThems Lazy Load" version 1.0, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
Please make the necessary changes and fix the following:
  • Text Domain: The text domain must be the same as the plugin slug, although optional since WordPress version 4.6
  • Main file name: Name the main plugin file the same as the plugin slug ("navthemes-lazy-load.php" instead of "navthemes-lazyload.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of programming languages used in this plugin; dangerous file extensions are not allowed
Success! There were no dangerous files found in this plugin334 lines of code in 3 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript201287
PHP1423847

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.20
Average class complexity0.00
▷ Minimum class complexity0.00
▷ Maximum class complexity0.00
Average method complexity0.00
▷ Minimum method complexity0.00
▷ Maximum method complexity0.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes0
▷ Abstract classes00.00%
▷ Concrete classes00.00%
▷ Final classes00.00%
Methods0
▷ Static methods00.00%
▷ Public methods00.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions3
▷ Named functions3100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Using a strong compression for your PNG files is a great way to speed-up your plugin
No PNG images were found in this plugin