67% block-editor-bootstrap-blocks

Code Review | Block Editor Bootstrap Blocks

WordPress plugin Block Editor Bootstrap Blocks scored67%from 54 tests.

About plugin

  • Plugin page: block-editor-boot...
  • Plugin version: 6.4.1
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.6-6.4
  • WordPress version: 6.3.1
  • First release: Jul 23, 2021
  • Latest release: Oct 25, 2023
  • Number of updates: 57
  • Update frequency: every 14.5 days
  • Top authors: kubiq (100%)

Code review

54 tests

User reviews

8 reviews

Install metrics

400+ active /4,899 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.45MB] [CPU: ▼8.83ms] Passed 4 tests

A check of server-side resources used by Block Editor Bootstrap Blocks
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.92 ▲0.4541.96 ▲5.90
Dashboard /wp-admin3.75 ▲0.4049.77 ▼11.34
Posts /wp-admin/edit.php3.84 ▲0.4843.80 ▼2.20
Add New Post /wp-admin/post-new.php7.87 ▲1.9875.81 ▼25.87
Media Library /wp-admin/upload.php3.69 ▲0.4538.90 ▲4.10

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

Filesystem and database footprint
No storage issues were detected
Filesystem: 244 new files
Database: no new tables, 6 new options
New WordPress options
can_compress_scripts
widget_recent-posts
widget_recent-comments
theysaidso_admin_options
db_upgraded
widget_theysaidso_widget

Browser metrics Passed 4 tests

Checking browser requirements for Block Editor Bootstrap Blocks
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,832 ▲8614.49 ▲0.144.44 ▲2.8445.24 ▲3.21
Dashboard /wp-admin2,199 ▲195.63 ▲0.0381.13 ▼6.5138.24 ▼0.54
Posts /wp-admin/edit.php2,107 ▲72.01 ▲0.0334.17 ▼8.0932.78 ▼2.70
Add New Post /wp-admin/post-new.php6,379 ▲4,84234.54 ▲16.071,090.87 ▲469.0957.08 ▼5.59
Media Library /wp-admin/upload.php1,407 ▲104.17 ▲0.0194.00 ▼8.3742.98 ▼0.18
Bootstrap Blocks /wp-admin/block-editor-bootstrap-blocks.php260.420.0913.37

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_recent-posts
    • theysaidso_admin_options
    • widget_recent-comments
    • db_upgraded
    • widget_theysaidso_widget
    • can_compress_scripts

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Everything seems fine, however this is by no means an exhaustive test

SRP 50% 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 fix the following items
  • 62× PHP files trigger server-side errors or warnings when accessed directly (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Interface 'Sabberworm\\CSS\\Property\\AtRule' not found in wp-content/plugins/block-editor-bootstrap-blocks/vendor/sabberworm/php-css-parser/src/Property/Charset.php:16
    • > PHP Fatal error
      Uncaught Error: Class 'ScssPhp\\ScssPhp\\Formatter' not found in wp-content/plugins/block-editor-bootstrap-blocks/vendor/scssphp/scssphp/src/Formatter/Expanded.php:24
    • > PHP Fatal error
      Uncaught Error: Class 'ScssPhp\\ScssPhp\\Formatter' not found in wp-content/plugins/block-editor-bootstrap-blocks/vendor/scssphp/scssphp/src/Formatter/Crunched.php:26
    • > PHP Fatal error
      Uncaught Error: Interface 'ScssPhp\\ScssPhp\\Logger\\LoggerInterface' not found in wp-content/plugins/block-editor-bootstrap-blocks/vendor/scssphp/scssphp/src/Logger/StreamLogger.php:20
    • > PHP Fatal error
      Uncaught Error: Interface 'ScssPhp\\ScssPhp\\Exception\\SassException' not found in wp-content/plugins/block-editor-bootstrap-blocks/vendor/scssphp/scssphp/src/Exception/ServerException.php:24
    • > PHP Fatal error
      Uncaught Error: Class 'Sabberworm\\CSS\\Parsing\\UnexpectedTokenException' not found in wp-content/plugins/block-editor-bootstrap-blocks/vendor/sabberworm/php-css-parser/src/Parsing/UnexpectedEOFException.php:10
    • > PHP Fatal error
      Uncaught Error: Class 'Padaliyajay\\PHPAutoprefixer\\Vendor\\Vendor' not found in wp-content/plugins/block-editor-bootstrap-blocks/vendor/padaliyajay/php-autoprefixer/src/Vendor/Mozilla.php:6
    • > PHP Fatal error
      Uncaught Error: Class 'ScssPhp\\ScssPhp\\Block' not found in wp-content/plugins/block-editor-bootstrap-blocks/vendor/scssphp/scssphp/src/Block/AtRootBlock.php:21
    • > PHP Fatal error
      Uncaught Error: Class 'ScssPhp\\ScssPhp\\Block' not found in wp-content/plugins/block-editor-bootstrap-blocks/vendor/scssphp/scssphp/src/Block/IfBlock.php:21
    • > PHP Fatal error
      Uncaught Error: Class 'Sabberworm\\CSS\\Value\\CSSFunction' not found in wp-content/plugins/block-editor-bootstrap-blocks/vendor/sabberworm/php-css-parser/src/Value/Color.php:10

User-side errors 0% from 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Please fix the following browser errors
    • > GET request to /wp-admin/block-editor-bootstrap-blocks.php
    • > Network (severe)
    wp-admin/block-editor-bootstrap-blocks.php - Failed to load resource: the server responded with a status of 404 (Not Found)

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
These attributes need your attention: You can take inspiration from this readme.txt

block-editor-bootstrap-blocks/block-editor-bootstrap-blocks.php 92% from 13 tests

Analyzing the main PHP file in "Block Editor Bootstrap Blocks" version 6.4.1
Please take the time to fix the following:
  • Text Domain: You no longer need to specify the text domain since WordPress 4.6; it must be the same as the plugin slug

Code Analysis 0% from 3 tests

File types 0% from 1 test

🔸 Test weight: 35 | This is an overview of file extensions present in this plugin and a short test that no dangerous files are bundled with this plugin
It is important to fix the following items
  • Even if your plugin relies on executable files (for example a companion app), never distribute executable files with your plugin
    • .bat - Batch File in Windows
      • wp-content/plugins/block-editor-bootstrap-blocks/vendor/bin/pscss.bat
25,581 lines of code in 235 files:
LanguageFilesBlank linesComment linesLines of code
PHP1214,1867,59617,013
Sass881,3391,2976,797
Markdown52100817
JSON1100697
CSS5226195
JavaScript4111058
DOS Batch1004

PHP code 0% from 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
These items need your attention
  • Cyclomatic complexity of classes should be reduced to less than 1000 (currently 1,493)
  • Method cyclomatic complexity has to be reduced to less than 100 (currently 198)
Cyclomatic complexity
Average complexity per logical line of code0.50
Average class complexity30.90
▷ Minimum class complexity1.00
▷ Maximum class complexity1,493.00
Average method complexity4.44
▷ Minimum method complexity1.00
▷ Maximum method complexity198.00
Code structure
Namespaces24
Interfaces5
Traits0
Classes104
▷ Abstract classes98.65%
▷ Concrete classes9591.35%
▷ Final classes33.16%
Methods921
▷ Static methods889.55%
▷ Public methods54659.28%
▷ Protected methods31033.66%
▷ Private methods657.06%
Functions38
▷ Named functions12.63%
▷ Anonymous functions3797.37%
Constants84
▷ Global constants00.00%
▷ Class constants84100.00%
▷ Public constants84100.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 files were detected