84% lsx-blocks

Code Review | LSX Blocks

WordPress plugin LSX Blocks scored84%from 54 tests.

About plugin

  • Plugin page: lsx-blocks
  • Plugin version: 1.3.3
  • PHP compatiblity: 8.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0-6.3
  • WordPress version: 6.3.1
  • First release: Jun 13, 2019
  • Latest release: Aug 10, 2023
  • Number of updates: 31
  • Update frequency: every 49.0 days
  • Top authors: feedmymedia (100%)

Code review

54 tests

User reviews

1 review

Install metrics

100+ active /6,055 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
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▼0.01MB] [CPU: ▼11.01ms] Passed 4 tests

A check of server-side resources used by LSX Blocks
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.79 ▲0.3339.70 ▼3.76
Dashboard /wp-admin3.61 ▲0.3151.04 ▼0.45
Posts /wp-admin/edit.php3.72 ▲0.3750.54 ▲5.57
Add New Post /wp-admin/post-new.php4.90 ▼0.9847.92 ▼45.40
Media Library /wp-admin/upload.php3.53 ▲0.3043.57 ▲6.24

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

Analyzing filesystem and database footprints of this plugin
There were no storage issued detected upon installing this plugin
Filesystem: 113 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-posts
can_compress_scripts
db_upgraded
widget_theysaidso_widget
widget_recent-comments
theysaidso_admin_options

Browser metrics Passed 4 tests

LSX Blocks: an overview of browser usage
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,905 ▲11913.81 ▼0.3810.00 ▲8.1339.29 ▼6.44
Dashboard /wp-admin2,200 ▲265.61 ▲0.0186.24 ▼4.3237.78 ▼2.93
Posts /wp-admin/edit.php2,099 ▲21.97 ▼0.0633.92 ▼6.2234.15 ▼0.26
Add New Post /wp-admin/post-new.php1,674 ▲14625.12 ▲1.87619.50 ▼83.4837.18 ▼20.67
Media Library /wp-admin/upload.php1,405 ▲54.18 ▲0.0097.01 ▼3.6568.51 ▲20.91

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
You still need to fix the following
  • This plugin does not fully uninstall, leaving 6 options in the database
    • widget_recent-posts
    • db_upgraded
    • widget_recent-comments
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • can_compress_scripts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Even though no errors were found, this is by no means an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
Please take a closer look at the following
  • 5× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/lsx-blocks/src/blocks/block-team/index.php:119
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/lsx-blocks/src/blocks/block-testimonials/index.php:99
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/lsx-blocks/src/blocks/block-post-carousel/index.php:365
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/lsx-blocks/src/blocks/block-post-grid/index.php:353
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/lsx-blocks/lsx-blocks.php:16

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
There were no browser issues found

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 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
6 plugin tags: wordpress blocks, block editor, lsx, blocks, page builder...

lsx-blocks/lsx-blocks.php 92% from 13 tests

The primary PHP file in "LSX Blocks" version 1.3.3 is used by WordPress to initiate all plugin functionality
It is important to fix the following:
  • Description: The description should be shorter than 140 characters (currently 158 characters long)

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is a short overview of programming languages used in this plugin, detecting executable files
Success! There were no dangerous files found in this plugin14,068 lines of code in 93 files:
LanguageFilesBlank linesComment linesLines of code
CSS151,856624,734
JavaScript294614484,334
Sass18230362,520
PHP174047381,852
JSON100192
Markdown21020188
YAML450185
XML113944
PO File11214
SVG5005

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
Everything seems fine, there were no complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.50
Average class complexity19.80
▷ Minimum class complexity2.00
▷ Maximum class complexity48.00
Average method complexity3.94
▷ Minimum method complexity1.00
▷ Maximum method complexity33.00
Code structure
Namespaces2
Interfaces0
Traits0
Classes5
▷ Abstract classes00.00%
▷ Concrete classes5100.00%
▷ Final classes00.00%
Methods32
▷ Static methods515.62%
▷ Public methods2681.25%
▷ Protected methods00.00%
▷ Private methods618.75%
Functions32
▷ Named functions2990.62%
▷ Anonymous functions39.38%
Constants4
▷ Global constants4100.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
1 PNG file occupies 0.00MB with 0.00MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
dist/assets/images/mystery-man-square.png2.46KB1.66KB▼ 32.70%