82% post-grid

Code Review | Post Grid Combo - 36+ Gutenberg Blocks

WordPress plugin Post Grid Combo - 36+ Gutenberg Blocks scored82%from 54 tests.

About plugin

  • Plugin page: post-grid
  • Plugin version: 2.2.64
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0.0-6.4
  • WordPress version: 6.3.1
  • First release: Feb 6, 2015
  • Latest release: Nov 21, 2023
  • Number of updates: 414
  • Update frequency: every 7.8 days
  • Top authors: pickplugins (81.16%)paratheme (19.08%)

Code review

54 tests

User reviews

157 reviews

Install metrics

50,000+ active /2,552,383 total downloads

Benchmarks

Plugin footprint 81% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
This plugin's installer ran successfully

Server metrics [RAM: ▲7.08MB] [CPU: ▲48.10ms] 25% from 4 tests

A check of server-side resources used by Post Grid Combo - 36+ Gutenberg Blocks
It is recommended to improve the following
  • RAM: Total memory usage must be kept under 10MB (currently 10.36MB on /wp-admin/admin.php?page=import_layouts)
  • CPU: Total CPU usage must kept under 500.00ms (currently 1,549.56ms on /wp-admin/admin.php?page=import_layouts)
  • Extra RAM: Extra memory usage must be kept under 5MB (currently 7.08MB on /wp-admin/admin.php?page=import_layouts)
PageMemory (MB)CPU Time (ms)
Home /10.71 ▲7.2476.93 ▲36.04
Dashboard /wp-admin10.33 ▲7.0396.89 ▲47.34
Posts /wp-admin/edit.php10.45 ▲7.0899.57 ▲49.94
Add New Post /wp-admin/post-new.php14.04 ▲8.15143.90 ▲61.26
Media Library /wp-admin/upload.php10.22 ▲6.9991.84 ▲59.09
All Saved Layouts /wp-admin/edit.php?post_type=post_grid_layout10.3079.11
Overview /wp-admin/admin.php?page=post-grid-overview10.2974.49
All Post Grid /wp-admin/edit.php?post_type=post_grid10.3095.83
All Saved Templates /wp-admin/edit.php?post_type=post_grid_template10.3077.44
Create New /wp-admin/post-new.php?post_type=post_grid10.4189.74
Settings /wp-admin/admin.php?page=post-grid-settings10.2680.96
Import Layouts /wp-admin/admin.php?page=import_layouts10.361,549.56

Server storage [IO: ▲53.16MB] [DB: ▲0.01MB] 67% from 3 tests

Input-output and database impact of this plugin
Just a few items left to fix
  • Total filesystem usage must be limited to 25MB (currently using 53.16MB)
Filesystem: 784 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-comments
theysaidso_admin_options
widget_theysaidso_widget
widget_recent-posts
db_upgraded
can_compress_scripts

Browser metrics Passed 4 tests

An overview of browser requirements for Post Grid Combo - 36+ Gutenberg Blocks
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,166 ▲40415.28 ▲1.055.73 ▲4.1637.59 ▼1.10
Dashboard /wp-admin2,447 ▲2676.15 ▲0.44120.25 ▲18.7341.26 ▼3.61
Posts /wp-admin/edit.php2,376 ▲2763.45 ▲1.5156.69 ▲15.7935.70 ▲5.40
Add New Post /wp-admin/post-new.php6,604 ▲5,07527.88 ▲4.261,090.64 ▲494.4279.20 ▲20.66
Media Library /wp-admin/upload.php1,512 ▲1124.19 ▼0.0683.17 ▼16.3940.36 ▼6.66
All Saved Layouts /wp-admin/edit.php?post_type=post_grid_layout1,3443.3254.2330.76
Overview /wp-admin/admin.php?page=post-grid-overview2,5449.68315.85141.52
All Post Grid /wp-admin/edit.php?post_type=post_grid1,3443.2549.8827.78
All Saved Templates /wp-admin/edit.php?post_type=post_grid_template1,3903.3052.7930.71
Create New /wp-admin/post-new.php?post_type=post_grid5,7827.65226.74135.18
Settings /wp-admin/admin.php?page=post-grid-settings1,9396.20117.1140.18
Import Layouts /wp-admin/admin.php?page=import_layouts1,8223.1144.4477.86

Uninstaller [IO: ▲0.00MB] [DB: ▲0.01MB] 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
  • This plugin does not fully uninstall, leaving 6 options in the database
    • db_upgraded
    • widget_recent-posts
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_theysaidso_widget
    • widget_recent-comments

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
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
The SRP test was a success

User-side errors 0% from 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Please take a look at the following user-side issues
    • > GET request to /wp-admin/admin.php?page=post-grid-overview
    • > Network (severe)
    https://getpostgrid.com/wp-content/uploads/2022/11/Post-Layout-Library.png - Failed to load resource: the server responded with a status of 404 ()

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

Don't ignore readme.txt as it is the file that instructs WordPress.org on how to present your plugin to the world
These attributes need your attention:
  • Screenshots: Please add an image for screenshot #2 (screenshot-2)
You can take inspiration from this readme.txt

post-grid/post-grid.php 92% from 13 tests

"Post Grid Combo - 36+ Gutenberg Blocks" version 2.2.64's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
Please make the necessary changes and fix the following:
  • Description: If Twitter did it, so should we! Keep the description under 140 characters (currently 149 characters long)

Code Analysis 97% from 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are considered dangerous and should not be included with any WordPress plugin
Good job! No executable or dangerous file extensions detected459,085 lines of code in 583 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript31342,06017,004333,172
PHP13619,7751,87043,383
CSS369,57647732,023
HTML22,099217,117
SVG901313,744
JSON804013,312
PO File52,3624,8785,246
Markdown15200791
XML160297

PHP code 50% from 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
It is recommended to fix the following
  • Cyclomatic complexity of methods should be reduced to less than 100 (currently 192)
Cyclomatic complexity
Average complexity per logical line of code0.54
Average class complexity62.55
▷ Minimum class complexity1.00
▷ Maximum class complexity663.00
Average method complexity10.83
▷ Minimum method complexity1.00
▷ Maximum method complexity192.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes91
▷ Abstract classes00.00%
▷ Concrete classes91100.00%
▷ Final classes00.00%
Methods572
▷ Static methods00.00%
▷ Public methods572100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions399
▷ Named functions34285.71%
▷ Anonymous functions5714.29%
Constants6
▷ Global constants6100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size 50% from 2 tests

Image compression 50% from 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
37 PNG files occupy 1.45MB with 0.73MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/admin/images/thumb.png993.82KB387.88KB▼ 60.97%
assets/frontend/images/placeholder.png32.82KB13.55KB▼ 58.71%
assets/admin/css/images/ui-icons_777620_256x240.png4.57KB4.18KB▼ 8.43%
assets/admin/css/images/ui-icons_777777_256x240.png6.85KB4.18KB▼ 38.94%
assets/admin/images/paddle-net.png26.23KB3.88KB▼ 85.19%