73% page-builder-sandwich

Code Review | Page Builder Sandwich – Front End WordPress Page Builder Plugin

WordPress plugin Page Builder Sandwich – Front End WordPress Page Builder Plugin scored 73% from 54 tests.

About plugin

  • Plugin page: page-builder-sand...
  • Plugin version: 5.1.0
  • PHP compatiblity: 5.3+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.5-6.1.1
  • WordPress version: 6.3.1
  • First release: Feb 15, 2015
  • Latest release: Feb 28, 2023
  • Number of updates: 219
  • Update frequency: every 13.4 days
  • Top authors: bfintal (93.15%)spartac (5.02%)pagebuildersandwich (2.74%)

Code review

54 tests

User reviews

104 reviews

Install metrics

10,000+ active / 207,737 total downloads

Benchmarks

Plugin footprint 65% 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.96MB] [CPU: ▲3.23ms] Passed 4 tests

Server-side resources used by Page Builder Sandwich – Front End WordPress Page Builder Plugin
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /5.21 ▲1.7553.60 ▲11.39
Dashboard /wp-admin4.10 ▲0.8049.52 ▼2.48
Posts /wp-admin/edit.php4.16 ▲0.8053.42 ▲13.25
Add New Post /wp-admin/post-new.php7.33 ▲1.44101.33 ▼2.57
Media Library /wp-admin/upload.php4.03 ▲0.8042.39 ▲6.56
Freemius Debug [v.2.5.3] /wp-admin/admin.php?page=freemius4.3536.34

Server storage [IO: ▲11.69MB] [DB: ▲0.08MB] Passed 3 tests

Filesystem and database footprint
There were no storage issued detected upon installing this plugin
Filesystem: 549 new files
Database: no new tables, 12 new options
New WordPress options
fs_gdpr
fs_active_plugins
pbs_install_date
fs_accounts
fs_debug_mode
pbs_no_migration_notice
theysaidso_admin_options
widget_recent-posts
can_compress_scripts
db_upgraded
...

Browser metrics Passed 4 tests

Checking browser requirements for Page Builder Sandwich – Front End WordPress Page Builder Plugin
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,919 ▲18413.32 ▼0.974.84 ▲3.1132.45 ▼13.10
Dashboard /wp-admin2,285 ▲935.93 ▲1.0299.11 ▼15.9881.97 ▲42.16
Posts /wp-admin/edit.php2,223 ▲1342.19 ▲0.1938.05 ▼0.0437.69 ▲1.47
Add New Post /wp-admin/post-new.php1,605 ▲7724.50 ▲6.62733.10 ▲114.0253.75 ▲0.93
Media Library /wp-admin/upload.php1,461 ▲734.22 ▲0.0498.30 ▼0.9073.60 ▲30.96
Freemius Debug [v.2.5.3] /wp-admin/admin.php?page=freemius1,0941.7425.2227.33

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
It is recommended to fix the following
  • The plugin did not uninstall gracefully
    • > Warning in wp-content/plugins/page-builder-sandwich/freemius/includes/fs-essential-functions.php+378
    Invalid argument supplied for foreach()
  • This plugin does not fully uninstall, leaving 10 options in the database
    • fs_active_plugins
    • fs_accounts
    • widget_recent-posts
    • fs_gdpr
    • can_compress_scripts
    • fs_debug_mode
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • widget_recent-comments
    • 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)
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
The following issues need your attention
  • 1× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_option() in wp-content/plugins/page-builder-sandwich/module-migration.php:450

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 93% from 29 tests

readme.txt Passed 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
10 plugin tags: wysiwyg builder, visual builder, website builder, site builder, homepage builder...

page-builder-sandwich/class-plugin.php 85% from 13 tests

The entry point to "Page Builder Sandwich – Front End WordPress Page Builder Plugin" version 5.1.0 is a PHP file that has certain tags in its header comment area
The following require your attention:
  • Main file name: The principal plugin file should be the same as the plugin slug ("page-builder-sandwich.php" instead of "class-plugin.php")
  • Description: Keep the plugin description shorter than 140 characters (currently 143 characters long)

Code Analysis 97% from 3 tests

File types Passed 1 test

🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
Good job! No executable or dangerous file extensions detected100,774 lines of code in 349 files:
LanguageFilesBlank linesComment linesLines of code
PHP1939,67520,15240,955
JavaScript358,00613,58429,273
CSS503,12832115,165
PO File115,6756,42112,608
SVG572552,530
Markdown1680214
JSON10027
Sass1002

PHP code 50% from 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
Please fix the following
  • Please reduce cyclomatic complexity of classes to less than 1000 (currently 3,089)
Cyclomatic complexity
Average complexity per logical line of code0.60
Average class complexity61.90
▷ Minimum class complexity1.00
▷ Maximum class complexity3,089.00
Average method complexity4.45
▷ Minimum method complexity1.00
▷ Maximum method complexity94.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes86
▷ Abstract classes22.33%
▷ Concrete classes8497.67%
▷ Final classes00.00%
Methods1,547
▷ Static methods20112.99%
▷ Public methods1,14774.14%
▷ Protected methods322.07%
▷ Private methods36823.79%
Functions109
▷ Named functions109100.00%
▷ Anonymous functions00.00%
Constants181
▷ Global constants13172.38%
▷ Class constants5027.62%
▷ Public constants50100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
7 PNG files occupy 0.12MB with 0.05MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
page_builder_sandwich/images/pbs-logo.png31.89KB17.05KB▼ 46.52%
freemius/assets/img/plugin-icon.png9.16KB5.26KB▼ 42.58%
freemius/assets/img/theme-icon.png10.97KB5.78KB▼ 47.37%
page_builder_sandwich/images/shortcode-icon.png5.82KB3.59KB▼ 38.28%
page_builder_sandwich/assets/element-icons/dashes.png0.31KB0.14KB▼ 53.04%