84% create-block-theme

Code Review | Create Block Theme

WordPress plugin Create Block Theme scored84%from 54 tests.

About plugin

  • Plugin page: create-block-theme
  • Plugin version: 1.13.7
  • PHP compatiblity: 7.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 6.0-6.4
  • WordPress version: 6.3.1
  • First release: Jun 16, 2022
  • Latest release: Dec 2, 2023
  • Number of updates: 47
  • Update frequency: every 11.4 days
  • Top authors: githubsync (95.74%)scruffian (6.38%)

Code review

54 tests

User reviews

24 reviews

Install metrics

7,000+ active /92,544 total downloads


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.58MB] [CPU: ▲3.48ms] Passed 4 tests

This is a short check of server-side resources used by Create Block Theme
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /4.05 ▲0.5844.50 ▲3.84
Dashboard /wp-admin3.89 ▲0.5852.24 ▲2.80
Posts /wp-admin/edit.php3.94 ▲0.5853.87 ▲2.67
Add New Post /wp-admin/post-new.php6.49 ▲0.6095.87 ▲8.92
Media Library /wp-admin/upload.php3.81 ▲0.5836.02 ▲4.62

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

A short overview of filesystem and database impact
There were no storage issued detected upon installing this plugin
Filesystem: 96 new files
Database: no new tables, 6 new options
New WordPress options

Browser metrics Passed 4 tests

This is an overview of browser requirements for Create Block Theme
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲3814.35 ▲0.171.60 ▼0.0338.84 ▼8.55
Dashboard /wp-admin2,202 ▲255.58 ▼0.0391.15 ▼6.2636.40 ▼7.62
Posts /wp-admin/edit.php2,112 ▲122.06 ▲0.1240.29 ▼0.7533.96 ▼2.68
Add New Post /wp-admin/post-new.php1,549 ▲2023.02 ▼0.14612.58 ▲35.0636.05 ▼14.45
Media Library /wp-admin/upload.php1,419 ▲164.18 ▼0.0895.57 ▼4.7841.05 ▼0.99

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
It is recommended to fix the following
  • The uninstall procedure has failed, leaving 6 options in the database
    • widget_recent-comments
    • widget_theysaidso_widget
    • widget_recent-posts
    • can_compress_scripts
    • theysaidso_admin_options
    • db_upgraded

Smoke tests 75% from 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)
The smoke test was a success, however most plugin functionality was not tested

SRP 50% from 2 tests

🔹 Tests weight: 20 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
The following issues need your attention
  • 2× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/create-block-theme/admin/resolver_additions.php:102
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/create-block-theme/admin/resolver_additions.php:102

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
Everything seems fine on the user side


Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
Please fix the following attributes: You can look at the official readme.txt

create-block-theme/create-block-theme.php Passed 13 tests

The main PHP file in "Create Block Theme" ver. 1.13.7 adds more information about the plugin and also serves as the entry point for this plugin
23 characters long description:
Generates a block theme

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
Success! There were no dangerous files found in this plugin45,411 lines of code in 91 files:
LanguageFilesBlank linesComment linesLines of code

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.29
Average class complexity14.72
▷ Minimum class complexity1.00
▷ Maximum class complexity65.00
Average method complexity3.69
▷ Minimum method complexity1.00
▷ Maximum method complexity32.00
Code structure
▷ Abstract classes00.00%
▷ Concrete classes25100.00%
▷ Final classes00.00%
▷ Static methods7557.69%
▷ Public methods12193.08%
▷ Protected methods64.62%
▷ Private methods32.31%
▷ Named functions321.43%
▷ Anonymous functions1178.57%
▷ Global constants00.00%
▷ Class constants4100.00%
▷ Public constants4100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
1 compressed PNG file occupies 0.05MB
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings