83% shared-vision-light

Code Review | Shared Vision Light

WordPress plugin Shared Vision Light scored83%from 54 tests.

About plugin

  • Plugin page: shared-vision-light
  • Plugin version: 1.1.0
  • PHP compatiblity: 5.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 2.1.0-6.4.1
  • WordPress version: 6.3.1
  • First release: May 17, 2023
  • Latest release: Nov 15, 2023
  • Number of updates: 3
  • Update frequency: every 60.7 days
  • Top authors: sharedvision (100%)

Code review

54 tests

User reviews

1 review

Install metrics

20+ active /324 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
Install script ran successfully

Server metrics [RAM: ▲0.05MB] [CPU: ▼5.17ms] Passed 4 tests

A check of server-side resources used by Shared Vision Light
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0132.78 ▼5.54
Dashboard /wp-admin3.37 ▲0.0748.18 ▲1.37
Posts /wp-admin/edit.php3.49 ▲0.1347.30 ▲2.71
Add New Post /wp-admin/post-new.php5.95 ▲0.0777.56 ▼14.88
Media Library /wp-admin/upload.php3.29 ▲0.0733.65 ▼1.61
Shared Vision /wp-admin/options-general.php?page=sharedvision-settings3.2730.55

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

Input-output and database impact of this plugin
The plugin installed successfully
Filesystem: 15 new files
Database: no new tables, 6 new options
New WordPress options
theysaidso_admin_options
widget_recent-comments
db_upgraded
widget_recent-posts
widget_theysaidso_widget
can_compress_scripts

Browser metrics Passed 4 tests

An overview of browser requirements for Shared Vision Light
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,855 ▲10814.33 ▼0.0264.76 ▲63.0943.68 ▼0.48
Dashboard /wp-admin2,199 ▲285.62 ▼0.0493.92 ▼4.1241.48 ▼0.48
Posts /wp-admin/edit.php2,104 ▲41.96 ▼0.0740.49 ▲0.8738.18 ▲1.01
Add New Post /wp-admin/post-new.php1,529 ▼022.97 ▼0.19624.86 ▼7.5054.66 ▲3.79
Media Library /wp-admin/upload.php1,407 ▲44.23 ▲0.02102.96 ▲7.9843.71 ▼1.27
Shared Vision /wp-admin/options-general.php?page=sharedvision-settings8112.1622.7425.87

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
These items require your attention
  • The uninstall procedure has failed, leaving 6 options in the database
    • widget_theysaidso_widget
    • widget_recent-posts
    • theysaidso_admin_options
    • widget_recent-comments
    • can_compress_scripts
    • db_upgraded

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Everything seems fine, however this is by no means an exhaustive test

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
Please take a closer look at the following
  • 2× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_html() in wp-content/plugins/shared-vision-light/templates/admin/settings.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_attr() in wp-content/plugins/shared-vision-light/templates/embed.php:1

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)
No browser errors were detected

Optimizations

Plugin configuration 86% from 29 tests

readme.txt 81% 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:
  • Plugin Name: Write the name of your plugin instead of "Plugin Name" on the first line ( === shared-vision-light === )
  • Screenshots: Add images for these screenshots: #1 (Shared Vision plugin settings), #2 (Shared Vision widget with simple design), #3 (Shared Vision widget with more elaborate design)
  • Tags: The plugin tags were not defined
You can look at the official readme.txt

shared-vision-light/sharedvision.php 92% from 13 tests

This is the main PHP file of "Shared Vision Light" version 1.1.0, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
The following require your attention:
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("shared-vision-light.php" instead of "sharedvision.php")

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 plugin300 lines of code in 11 files:
LanguageFilesBlank linesComment linesLines of code
PHP1112445300

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.32
Average class complexity5.33
▷ Minimum class complexity1.00
▷ Maximum class complexity11.00
Average method complexity2.00
▷ Minimum method complexity1.00
▷ Maximum method complexity7.00
Code structure
Namespaces3
Interfaces0
Traits0
Classes6
▷ Abstract classes00.00%
▷ Concrete classes6100.00%
▷ Final classes00.00%
Methods23
▷ Static methods1043.48%
▷ Public methods23100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions5
▷ Named functions360.00%
▷ Anonymous functions240.00%
Constants14
▷ Global constants642.86%
▷ Class constants857.14%
▷ Public constants8100.00%

Plugin size 50% from 2 tests

Image compression 50% from 2 tests

Using a strong compression for your PNG files is a great way to speed-up your plugin
3 PNG files occupy 2.57MB with 1.90MB in potential savings
Potential savings
Compression of 3 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/screenshot-3.png695.49KB180.38KB▼ 74.06%
assets/screenshot-1.png95.22KB25.03KB▼ 73.72%
assets/screenshot-2.png1,839.66KB478.96KB▼ 73.96%