84% editor-blocks

Code Review | Editor Blocks for Gutenberg

WordPress plugin Editor Blocks for Gutenberg scored84%from 54 tests.

About plugin

  • Plugin page: editor-blocks
  • Plugin version: 1.2.1
  • PHP compatiblity: 5.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.9-5.5
  • WordPress version: 6.3.1
  • First release: Aug 12, 2018
  • Latest release: Aug 12, 2020
  • Number of updates: 26
  • Update frequency: every 32.2 days
  • Top authors: DannyCooper (100%)

Code review

54 tests

User reviews

2 reviews

Install metrics

1,000+ active /29,536 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
This plugin's installer ran successfully

Server metrics [RAM: ▼0.22MB] [CPU: ▼13.67ms] Passed 4 tests

Server-side resources used by Editor Blocks for Gutenberg
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.52 ▲0.0540.54 ▼5.29
Dashboard /wp-admin3.35 ▲0.0447.68 ▼0.39
Posts /wp-admin/edit.php3.40 ▲0.0449.38 ▼4.34
Add New Post /wp-admin/post-new.php4.86 ▼1.0356.11 ▼44.67
Media Library /wp-admin/upload.php3.27 ▲0.0437.39 ▲3.19

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

Filesystem and database footprint
This plugin was installed successfully
Filesystem: 73 new files
Database: no new tables, 6 new options
New WordPress options
db_upgraded
widget_recent-comments
theysaidso_admin_options
can_compress_scripts
widget_recent-posts
widget_theysaidso_widget

Browser metrics Passed 4 tests

A check of browser resources used by Editor Blocks for Gutenberg
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,820 ▲7413.25 ▼1.501.66 ▼0.2740.96 ▼5.92
Dashboard /wp-admin2,224 ▲395.80 ▼0.06101.34 ▼0.2241.71 ▼1.28
Posts /wp-admin/edit.php2,110 ▲242.05 ▼0.0040.98 ▲0.9934.94 ▼4.71
Add New Post /wp-admin/post-new.php6,369 ▲4,82528.28 ▲9.96836.02 ▲238.3156.26 ▲2.55
Media Library /wp-admin/upload.php1,403 ▲154.29 ▲0.0593.46 ▼4.5841.94 ▼0.73

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
The following items require your attention
  • This plugin did not uninstall successfully, 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 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Even though everything seems fine, this is not an exhaustive test

SRP 50% from 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
Please fix the following
  • 2× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function is_admin() in wp-content/plugins/editor-blocks/admin/welcome.php:207
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/editor-blocks/src/author/index.php:29

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 96% from 29 tests

readme.txt Passed 16 tests

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

editor-blocks/plugin.php 92% from 13 tests

This is the main PHP file of "Editor Blocks for Gutenberg" version 1.2.1, 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:
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("editor-blocks.php" instead of "plugin.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
No dangerous file extensions were detected3,863 lines of code in 55 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript271921182,730
Sass211270724
PHP44779260
CSS3190149

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.19
Average class complexity4.00
▷ Minimum class complexity4.00
▷ Maximum class complexity4.00
Average method complexity1.75
▷ Minimum method complexity1.00
▷ Maximum method complexity4.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods4
▷ Static methods00.00%
▷ Public methods4100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions7
▷ Named functions685.71%
▷ Anonymous functions114.29%
Constants1
▷ Global constants1100.00%
▷ Class constants00.00%
▷ Public constants00.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
11 PNG files occupy 0.01MB with 0.00MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
admin/images/information-outline.png1.66KB0.87KB▼ 47.23%
admin/images/arrow-thin-down.png0.65KB0.41KB▼ 37.01%
admin/images/list-bullet.png0.23KB0.12KB▼ 48.29%
admin/images/announcement.png0.60KB0.39KB▼ 35.39%
admin/images/badge.png1.18KB0.62KB▼ 47.22%