84% indieblocks

Code Review | IndieBlocks

WordPress plugin IndieBlocks scored84%from 54 tests.

About plugin

  • Plugin page: indieblocks
  • Plugin version: 0.10.0
  • PHP version: 7.4.16
  • WordPress compatibility: 6.2-6.4
  • WordPress version: 6.3.1
  • First release: Oct 14, 2022
  • Latest release: Nov 28, 2023
  • Number of updates: 13
  • Update frequency: every 31.5 days
  • Top authors: janboddez (100%)

Code review

54 tests

User reviews

3 reviews

Install metrics

30+ active /1,403 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
Install script ran successfully

Server metrics [RAM: ▲1.09MB] [CPU: ▲1.84ms] Passed 4 tests

A check of server-side resources used by IndieBlocks
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /4.58 ▲1.1243.54 ▼0.48
Dashboard /wp-admin4.40 ▲1.0658.83 ▼5.61
Posts /wp-admin/edit.php4.46 ▲1.1055.91 ▲11.60
Add New Post /wp-admin/post-new.php7.05 ▲1.1695.86 ▲1.85
Media Library /wp-admin/upload.php4.33 ▲1.1050.43 ▲17.71
IndieBlocks /wp-admin/options-general.php?page=indieblocks4.2934.13

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

A short overview of filesystem and database impact
This plugin installed successfully
Filesystem: 111 new files
Database: no new tables, 7 new options
New WordPress options
theysaidso_admin_options
widget_recent-comments
indieblocks_settings
can_compress_scripts
widget_theysaidso_widget
widget_recent-posts
db_upgraded

Browser metrics Passed 4 tests

IndieBlocks: an overview of browser usage
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,794 ▲4714.72 ▲0.361.61 ▼0.1739.73 ▼3.76
Dashboard /wp-admin2,199 ▲185.62 ▼0.0695.62 ▼12.5542.37 ▼3.77
Posts /wp-admin/edit.php2,104 ▲71.99 ▲0.0239.44 ▲2.2636.44 ▲1.49
Add New Post /wp-admin/post-new.php6,423 ▲4,89728.31 ▲5.35883.20 ▲279.3236.61 ▼14.26
Media Library /wp-admin/upload.php1,407 ▲74.16 ▼0.0294.81 ▼1.9841.42 ▼3.14
IndieBlocks /wp-admin/options-general.php?page=indieblocks8962.1823.9727.70

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
You still need to fix the following
  • Zombie WordPress options were found after uninstall: 7 options
    • theysaidso_admin_options
    • db_upgraded
    • can_compress_scripts
    • widget_recent-posts
    • widget_recent-comments
    • indieblocks_settings
    • widget_theysaidso_widget

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
The smoke test was a success, however most plugin functionality was not tested

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
The following issues need your attention
  • 19× GET requests to PHP files have triggered server-side errors or warnings (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Class 'IndieBlocks\\Michelf\\Markdown' not found in wp-content/plugins/indieblocks/build/vendor/michelf/php-markdown/Michelf/MarkdownExtra.php:16
    • > PHP Fatal error
      Uncaught Error: Interface 'IndieBlocks\\Michelf\\MarkdownInterface' not found in wp-content/plugins/indieblocks/build/vendor/michelf/php-markdown/Michelf/Markdown.php:16
    • > PHP Fatal error
      Uncaught Error: Class 'IndieBlocks\\Plugin' not found in wp-content/plugins/indieblocks/blocks/location/block.asset.php:4
    • > PHP Fatal error
      Uncaught Error: Class 'IndieBlocks\\Masterminds\\HTML5\\Parser\\StringInputStream' not found in wp-content/plugins/indieblocks/build/vendor/masterminds/html5/src/HTML5/Parser/FileInputStream.php:17
    • > PHP Fatal error
      Uncaught Error: Class 'IndieBlocks\\Plugin' not found in wp-content/plugins/indieblocks/blocks/context/block.asset.php:4
    • > PHP Fatal error
      Uncaught Error: Class 'IndieBlocks\\Plugin' not found in wp-content/plugins/indieblocks/blocks/link-preview/block.asset.php:4
    • > PHP Fatal error
      Uncaught Error: Interface 'IndieBlocks\\Masterminds\\HTML5\\Serializer\\RulesInterface' not found in wp-content/plugins/indieblocks/build/vendor/masterminds/html5/src/HTML5/Serializer/OutputRules.php:16
    • > PHP Fatal error
      require(): Failed opening required 'IndieBlocks/Michelf/Markdown.php' (include_path='.:/usr/share/php') in wp-content/plugins/indieblocks/build/vendor/michelf/php-markdown/Readme.php on line 10
    • > PHP Fatal error
      Uncaught Error: Class 'IndieBlocks\\Plugin' not found in wp-content/plugins/indieblocks/blocks/repost/block.asset.php:4
    • > PHP Fatal error
      Uncaught Error: Class 'IndieBlocks\\Plugin' not found in wp-content/plugins/indieblocks/blocks/facepile-content/block.asset.php:4

User-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
There were no browser issues found

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

You should put a lot of thought into formatting readme.txt as it is used by WordPress.org to prepare the public listing of your plugin
Attributes that require attention:
  • Tags: Please delete some tags, you are using 12 tag instead of maximum 10
You can take inspiration from this readme.txt

indieblocks/indieblocks.php Passed 13 tests

This is the main PHP file of "IndieBlocks" version 0.10.0, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
82 characters long description:
Leverage blocks and custom post types to easily "IndieWebify" your WordPress site.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of programming languages used in this plugin; dangerous file extensions are not allowed
There were no executable files found in this plugin11,861 lines of code in 95 files:
LanguageFilesBlank linesComment linesLines of code
PHP691,2415,98310,129
JavaScript12151641,193
JSON1000426
CSS3181100
SVG10013

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.46
Average class complexity37.98
▷ Minimum class complexity1.00
▷ Maximum class complexity301.00
Average method complexity4.77
▷ Minimum method complexity1.00
▷ Maximum method complexity71.00
Code structure
Namespaces9
Interfaces5
Traits0
Classes42
▷ Abstract classes00.00%
▷ Concrete classes42100.00%
▷ Final classes00.00%
Methods489
▷ Static methods14830.27%
▷ Public methods32766.87%
▷ Protected methods14930.47%
▷ Private methods132.66%
Functions45
▷ Named functions4293.33%
▷ Anonymous functions36.67%
Constants65
▷ Global constants00.00%
▷ Class constants65100.00%
▷ Public constants65100.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.00MB
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
assets/mm.png1.13KB1.23KB0.00%