90% contentblocks

Code Review | Content Blocks

WordPress plugin Content Blocks scored90%from 54 tests.

About plugin

  • Plugin page: contentblocks
  • Plugin version: 0.0.1
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.9+
  • WordPress version: 6.3.1
  • First release: Feb 6, 2018
  • Latest release: Feb 24, 2018
  • Number of updates: 4
  • Update frequency: every 18.5 days
  • Top authors: Gwendydd (75%)range (50%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /689 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
The plugin installed successfully, without throwing any errors or notices

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

Server-side resources used by Content Blocks
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.49 ▲0.0238.34 ▼1.00
Dashboard /wp-admin3.32 ▼0.0347.89 ▼11.34
Posts /wp-admin/edit.php3.37 ▲0.0144.53 ▼2.98
Add New Post /wp-admin/post-new.php7.00 ▲1.1187.91 ▼2.63
Media Library /wp-admin/upload.php3.24 ▲0.0132.78 ▼2.86

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

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

Browser metrics Passed 4 tests

This is an overview of browser requirements for Content Blocks
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,988 ▲22719.18 ▲4.83151.06 ▲149.2738.13 ▼5.02
Dashboard /wp-admin2,195 ▲185.51 ▼0.1179.64 ▼9.2340.71 ▲2.91
Posts /wp-admin/edit.php2,100 ▼01.96 ▼0.0736.26 ▲2.2133.83 ▼0.91
Add New Post /wp-admin/post-new.php6,201 ▲4,66626.89 ▲8.43886.37 ▲269.9433.72 ▼36.80
Media Library /wp-admin/upload.php1,394 ▼34.24 ▲0.0298.37 ▼1.7340.92 ▼3.15

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

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
Good news, no errors were detected

SRP Passed 2 tests

🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
Everything seems fine, however this is by no means an exhaustive test

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
No browser errors were detected

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
2 plugin tags: blocks, gutenberg

contentblocks/contentblocks.php Passed 13 tests

The main file in "Content Blocks" v. 0.0.1 serves as a complement to information provided in readme.txt and as the entry point to the plugin
40 characters long description:
Beautiful blocks for your WordPress site

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 plugin10,467 lines of code in 17 files:
LanguageFilesBlank linesComment linesLines of code
JSON2009,167
JavaScript93652781,098
PHP1314278
SVG10176
Sass25026
CSS22022

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.18
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%
Functions4
▷ Named functions4100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
There are no PNG files in this plugin