71% best-wp-lightweight

Code Review | WOW Best WP Lightweight

WordPress plugin WOW Best WP Lightweight scored71%from 54 tests.

About plugin

  • Plugin page: best-wp-lightweight
  • Plugin version: 2.1.0
  • PHP compatiblity: 7.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.7-6.1
  • WordPress version: 6.3.1
  • First release: Aug 27, 2021
  • Latest release: Oct 30, 2022
  • Number of updates: 10
  • Update frequency: every 42.9 days
  • Top authors: baonguyenyam (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /517 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

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

Server metrics [RAM: ▲1.74MB] [CPU: ▲23.29ms] Passed 4 tests

Analyzing server-side resources used by WOW Best WP Lightweight
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /5.23 ▲1.7787.93 ▲43.74
Dashboard /wp-admin5.09 ▲1.7581.95 ▲12.34
Posts /wp-admin/edit.php5.15 ▲1.7983.08 ▲27.61
Add New Post /wp-admin/post-new.php7.63 ▲1.74121.94 ▲13.88
Media Library /wp-admin/upload.php4.93 ▲1.7080.99 ▲39.34

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

Analyzing filesystem and database footprints of this plugin
This plugin was installed successfully
Filesystem: 582 new files
Database: no new tables, 6 new options
New WordPress options
db_upgraded
widget_theysaidso_widget
widget_recent-posts
can_compress_scripts
theysaidso_admin_options
widget_recent-comments

Browser metrics Passed 4 tests

A check of browser resources used by WOW Best WP Lightweight
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,108 ▲34718.53 ▲4.301.78 ▲0.0240.09 ▼3.40
Dashboard /wp-admin2,521 ▲3189.25 ▲4.38177.97 ▲70.6739.69 ▼3.22
Posts /wp-admin/edit.php2,426 ▲3266.23 ▲4.2179.90 ▲42.0331.57 ▼2.47
Add New Post /wp-admin/post-new.php1,867 ▲33522.17 ▼1.25653.62 ▼38.4637.32 ▼19.16
Media Library /wp-admin/upload.php1,560 ▲1636.54 ▲2.28112.25 ▼4.6944.37 ▼3.16
WP Lightweight /wp-admin/crb_carbon_fields_container_best_wp_lightweight.php260.440.1315.18

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
The following items require your attention
  • The uninstall procedure has failed, leaving 6 options in the database
    • can_compress_scripts
    • db_upgraded
    • widget_recent-comments
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • widget_recent-posts

Smoke tests 25% from 4 tests

Server-side errors Passed 1 test

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

SRP 0% from 2 tests

🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
Please take a closer look at the following
  • 1× PHP files output non-empty strings when accessed directly via GET requests:
    • > /wp-content/plugins/best-wp-lightweight/vendor/htmlburger/carbon-fields/templates/Exception/incorrect-syntax.php
  • 215× GET requests to PHP files trigger server-side errors or Error 500 responses (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Class 'Composer\\Installers\\BaseInstaller' not found in wp-content/plugins/best-wp-lightweight/vendor/composer/installers/src/Composer/Installers/Symfony1Installer.php:9
    • > PHP Fatal error
      Uncaught Error: Using $this when not in object context in wp-content/plugins/best-wp-lightweight/vendor/htmlburger/carbon-fields/templates/Container/nav_menu_item.php:1
    • > PHP Fatal error
      Uncaught Error: Class 'Composer\\Installers\\BaseInstaller' not found in wp-content/plugins/best-wp-lightweight/vendor/composer/installers/src/Composer/Installers/PhpBBInstaller.php:4
    • > PHP Fatal error
      Uncaught Error: Class 'Carbon_Fields\\Container\\Condition\\Comparer\\Comparer' not found in wp-content/plugins/best-wp-lightweight/vendor/htmlburger/carbon-fields/core/Container/Condition/Comparer/Any_Contain_Comparer.php:7
    • > PHP Notice
      Undefined variable: plural in wp-content/plugins/best-wp-lightweight/vendor/htmlburger/carbon-fields/templates/Exception/incorrect-syntax.php on line 32
    • > PHP Fatal error
      Uncaught Error: Class 'Composer\\Installers\\BaseInstaller' not found in wp-content/plugins/best-wp-lightweight/vendor/composer/installers/src/Composer/Installers/CockpitInstaller.php:4
    • > PHP Fatal error
      Uncaught Error: Class 'Carbon_Fields\\Field\\Select_Field' not found in wp-content/plugins/best-wp-lightweight/vendor/htmlburger/carbon-fields/core/Field/Radio_Field.php:8
    • > PHP Fatal error
      Uncaught Error: Class 'Carbon_Fields\\Field\\Field' not found in wp-content/plugins/best-wp-lightweight/vendor/htmlburger/carbon-fields/core/Field/Html_Field.php:11
    • > PHP Fatal error
      Uncaught Error: Class 'Composer\\Installers\\BaseInstaller' not found in wp-content/plugins/best-wp-lightweight/vendor/composer/installers/src/Composer/Installers/OntoWikiInstaller.php:4
    • > PHP Fatal error
      Uncaught Error: Class 'Composer\\Installers\\BaseInstaller' not found in wp-content/plugins/best-wp-lightweight/vendor/composer/installers/src/Composer/Installers/LaravelInstaller.php:4

User-side errors 0% from 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Please take a look at the following user-side issues
    • > GET request to /wp-admin/crb_carbon_fields_container_best_wp_lightweight.php
    • > Network (severe)
    wp-admin/crb_carbon_fields_container_best_wp_lightweight.php - Failed to load resource: the server responded with a status of 404 (Not Found)

Optimizations

Plugin configuration 83% from 29 tests

readme.txt 81% from 16 tests

Don't ignore readme.txt as it is the file that instructs WordPress.org on how to present your plugin to the world
Attributes that need to be fixed:
  • Screenshots: These screenshots lack descriptions #1, #2, #3, #4, #5, #6, #7 in best-wp-lightweight/assets to your readme.txt
  • Plugin Name: Write the name of your plugin instead of "Plugin Name" on the first line ( === best-wp-lightweight === )
  • Tags: You are using too many tags: 36 tag instead of maximum 10
The official readme.txt is a good inspiration

best-wp-lightweight/nguyen-app.php 85% from 13 tests

The entry point to "WOW Best WP Lightweight" version 2.1.0 is a PHP file that has certain tags in its header comment area
The following require your attention:
  • Description: Keep the plugin description shorter than 140 characters (currently 151 characters long)
  • Main file name: The principal plugin file should be the same as the plugin slug ("best-wp-lightweight.php" instead of "nguyen-app.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 plugin31,153 lines of code in 524 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript1715,1888,45912,933
PHP2582,9537,45711,499
PO File268191,0202,202
Sass4934211,896
CSS93291,1391,779
JSON500658
YAML3303118
Markdown324068

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.27
Average class complexity5.57
▷ Minimum class complexity1.00
▷ Maximum class complexity50.00
Average method complexity2.03
▷ Minimum method complexity1.00
▷ Maximum method complexity21.00
Code structure
Namespaces23
Interfaces5
Traits0
Classes232
▷ Abstract classes125.17%
▷ Concrete classes22094.83%
▷ Final classes10.45%
Methods1,063
▷ Static methods928.65%
▷ Public methods84279.21%
▷ Protected methods19918.72%
▷ Private methods222.07%
Functions116
▷ Named functions2622.41%
▷ Anonymous functions9077.59%
Constants36
▷ Global constants925.00%
▷ Class constants2775.00%
▷ Public constants27100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
2 PNG files occupy 0.02MB with 0.01MB in potential savings
Potential savings
Compression of 2 random PNG files using pngquant
FileSize - originalSize - compressedSavings
admin/assets/img/icon.png10.50KB5.29KB▼ 49.68%
admin/assets/img/logo.png14.66KB7.71KB▼ 47.40%