89% woo-blocks

Code Review | Awesome blocks for WooCommerce

WordPress plugin Awesome blocks for WooCommerce scored89%from 54 tests.

About plugin

  • Plugin page: woo-blocks
  • Plugin version: 1.0.0
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0-5.2
  • WordPress version: 6.3.1
  • First release: Oct 7, 2019
  • Latest release: Oct 7, 2019
  • Number of updates: 4
  • Update frequency: every 0.3 days
  • Top authors: jmsthemes (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /641 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

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

Server metrics [RAM: ▲0.00MB] [CPU: ▼4.36ms] Passed 4 tests

Server-side resources used by Awesome blocks for WooCommerce
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0042.83 ▼1.70
Dashboard /wp-admin3.31 ▲0.0048.28 ▲1.64
Posts /wp-admin/edit.php3.36 ▲0.0050.53 ▼2.22
Add New Post /wp-admin/post-new.php5.89 ▲0.0084.05 ▼11.31
Media Library /wp-admin/upload.php3.23 ▲0.0036.05 ▼2.21

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

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

Browser metrics Passed 4 tests

An overview of browser requirements for Awesome blocks for WooCommerce
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,814 ▲5314.24 ▼0.111.94 ▲0.0346.15 ▲1.08
Dashboard /wp-admin2,198 ▲215.55 ▼0.0991.98 ▼5.4938.54 ▼1.39
Posts /wp-admin/edit.php2,097 ▼32.03 ▲0.0236.58 ▼4.7330.87 ▼5.79
Add New Post /wp-admin/post-new.php1,526 ▼023.63 ▲0.50657.70 ▼44.7557.07 ▼5.05
Media Library /wp-admin/upload.php1,400 ▲94.23 ▲0.0399.17 ▼4.6141.86 ▼5.08

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
Please fix the following items
  • Zombie WordPress options were found after uninstall: 6 options
    • can_compress_scripts
    • widget_recent-comments
    • widget_recent-posts
    • widget_theysaidso_widget
    • db_upgraded
    • theysaidso_admin_options

Smoke tests Passed 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 Passed 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
The SRP test was a success

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
There were no browser issues found

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file is an important file in your plugin as it is parsed by WordPress.org to prepare the public listing of your plugin
These attributes need your attention:
  • Screenshots: These screenshots lack descriptions #1, #2, #3, #4, #5, #6, #7, #8 in woo-blocks/assets to your readme.txt
You can look at the official readme.txt

woo-blocks/jms-wooblocks.php 85% from 13 tests

The main PHP script in "Awesome blocks for WooCommerce" version 1.0.0 is automatically included on every request by WordPress
You should first fix the following items:
  • Text Domain: The text domain is optional since WordPress version 4.6; if you do specify it, it must be the same as the plugin slug
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("woo-blocks.php" instead of "jms-wooblocks.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
Everything looks great! No dangerous files found in this plugin915 lines of code in 41 files:
LanguageFilesBlank linesComment linesLines of code
PHP20176356877
JavaScript1366123
JSON60012
CSS2003

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
Everything seems fine, there were no complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.42
Average class complexity8.00
▷ Minimum class complexity1.00
▷ Maximum class complexity44.00
Average method complexity3.39
▷ Minimum method complexity1.00
▷ Maximum method complexity27.00
Code structure
Namespaces4
Interfaces0
Traits0
Classes15
▷ Abstract classes16.67%
▷ Concrete classes1493.33%
▷ Final classes00.00%
Methods45
▷ Static methods817.78%
▷ Public methods3884.44%
▷ Protected methods613.33%
▷ Private methods12.22%
Functions4
▷ Named functions375.00%
▷ Anonymous functions125.00%
Constants7
▷ Global constants7100.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