84% livereload

Code Review | LiveReload Snippet

WordPress plugin LiveReload Snippet scored84%from 54 tests.

About plugin

  • Plugin page: livereload
  • Plugin version: 2.0
  • PHP version: 7.4.16
  • WordPress compatibility: 1.2.0-6.1
  • WordPress version: 6.3.1
  • First release: Jun 13, 2012
  • Latest release: Feb 15, 2023
  • Number of updates: 11
  • Update frequency: every 354.5 days
  • Top authors: functionsfile (100%)

Code review

54 tests

User reviews

4 reviews

Install metrics

10+ active /2,097 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 gracefully, with no errors

Server metrics [RAM: ▲0.00MB] [CPU: ▼4.56ms] Passed 4 tests

This is a short check of server-side resources used by LiveReload Snippet
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0035.19 ▼0.15
Dashboard /wp-admin3.31 ▲0.0148.27 ▼2.00
Posts /wp-admin/edit.php3.36 ▲0.0050.71 ▲3.51
Add New Post /wp-admin/post-new.php5.91 ▲0.0283.69 ▼14.47
Media Library /wp-admin/upload.php3.23 ▲0.0033.56 ▼1.60

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

Filesystem and database footprint
This plugin was installed successfully
Filesystem: 3 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-posts
db_upgraded
theysaidso_admin_options
widget_theysaidso_widget
widget_recent-comments
can_compress_scripts

Browser metrics Passed 4 tests

An overview of browser requirements for LiveReload Snippet
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,905 ▲14413.47 ▼1.1112.44 ▲10.7641.58 ▲0.07
Dashboard /wp-admin2,204 ▲275.75 ▲0.1488.16 ▼0.7136.49 ▲0.13
Posts /wp-admin/edit.php2,106 ▲32.06 ▲0.0639.53 ▲0.5931.91 ▼0.65
Add New Post /wp-admin/post-new.php1,531 ▲523.01 ▼0.24618.52 ▲4.1847.22 ▼8.46
Media Library /wp-admin/upload.php1,400 ▼34.24 ▲0.12104.87 ▲4.7240.99 ▼3.87

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
The following items require your attention
  • This plugin does not fully uninstall, leaving 6 options in the database
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • widget_recent-posts
    • widget_recent-comments
    • db_upgraded
    • can_compress_scripts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Even though everything seems fine, this is not an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
Please take a closer look at the following
  • 1× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/livereload/livereload.php:28

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
No browser errors were detected

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 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
2 plugin tags: javascript, livereload

livereload/livereload.php Passed 13 tests

The primary PHP file in "LiveReload Snippet" version 2.0 is used by WordPress to initiate all plugin functionality
66 characters long description:
Add the LiveReload javascript snippet to the footer of your theme.

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
Good job! No executable or dangerous file extensions detected21 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code
PHP133112
JavaScript1009

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.00
Average class complexity0.00
▷ Minimum class complexity0.00
▷ Maximum class complexity0.00
Average method complexity0.00
▷ Minimum method complexity0.00
▷ Maximum method complexity0.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes0
▷ Abstract classes00.00%
▷ Concrete classes00.00%
▷ Final classes00.00%
Methods0
▷ Static methods00.00%
▷ Public methods00.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions1
▷ Named functions1100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Using a strong compression for your PNG files is a great way to speed-up your plugin
There were not PNG files found in your plugin