89% scroll-styler

Code Review | Scroll Styler

WordPress plugin Scroll Styler scored89%from 54 tests.

About plugin

  • Plugin page: scroll-styler
  • Plugin version: 1.1
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-6.2
  • WordPress version: 6.3.1
  • First release: Sep 15, 2018
  • Latest release: Apr 2, 2023
  • Number of updates: 27
  • Update frequency: every 61.5 days
  • Top authors: jablonczay (100%)

Code review

54 tests

User reviews

1 review

Install metrics

1,000+ active /5,188 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.15MB] [CPU: ▼13.24ms] Passed 4 tests

Analyzing server-side resources used by Scroll Styler
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /2.75 ▼0.7114.77 ▼23.98
Dashboard /wp-admin3.34 ▲0.0448.02 ▲2.87
Posts /wp-admin/edit.php3.39 ▲0.0446.34 ▼3.98
Add New Post /wp-admin/post-new.php5.92 ▲0.0483.21 ▼24.52
Media Library /wp-admin/upload.php3.26 ▲0.0434.40 ▼0.48
Scroll Styler /wp-admin/options-general.php?page=scroll-styler3.2632.32

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

A short overview of filesystem and database impact
This plugin installed successfully
Filesystem: 30 new files
Database: no new tables, 7 new options
New WordPress options
db_upgraded
widget_recent-posts
widget_recent-comments
widget_theysaidso_widget
can_compress_scripts
scrollStylerOptions
theysaidso_admin_options

Browser metrics Passed 4 tests

Scroll Styler: an overview of browser usage
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,807 ▲6113.70 ▼0.731.83 ▼0.0945.15 ▲2.40
Dashboard /wp-admin2,207 ▲195.79 ▲0.8898.64 ▼11.3339.89 ▼4.29
Posts /wp-admin/edit.php2,093 ▲12.05 ▲0.0336.32 ▼4.2431.40 ▼6.65
Add New Post /wp-admin/post-new.php1,545 ▲1718.38 ▲0.33594.11 ▼18.7455.91 ▼0.13
Media Library /wp-admin/upload.php1,383 ▼24.18 ▼0.0198.68 ▼2.9642.62 ▼0.91
Scroll Styler /wp-admin/options-general.php?page=scroll-styler1,1201.9433.3850.95

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

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

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

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

SRP Passed 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
Looking good! No server-side errors or output on direct access of PHP files

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 93% from 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
8 plugin tags: custom, scrollbar, thumb, scroll, style...

scroll-styler/ScrollStyler.php 85% from 13 tests

The primary PHP file in "Scroll Styler" version 1.1 is used by WordPress to initiate all plugin functionality
You should first fix the following items:
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("scroll-styler.php" instead of "ScrollStyler.php")
  • Text Domain: The text domain name should consist of only dashes and lowercase characters

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of programming languages used in this plugin; dangerous file extensions are not allowed
Success! There were no dangerous files found in this plugin1,631 lines of code in 12 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript3139162850
CSS24810460
PHP49793269
PO File1141450
SVG2002

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.22
Average class complexity5.33
▷ Minimum class complexity4.00
▷ Maximum class complexity7.00
Average method complexity1.65
▷ Minimum method complexity1.00
▷ Maximum method complexity5.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes3
▷ Abstract classes00.00%
▷ Concrete classes3100.00%
▷ Final classes00.00%
Methods20
▷ Static methods525.00%
▷ Public methods1785.00%
▷ Protected methods00.00%
▷ Private methods315.00%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
6 PNG files occupy 0.07MB with 0.01MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/img/gdpr-cookie-law-responsive-javascript-gdpr-consent-plugin.png0.79KB0.78KB▼ 1.98%
assets/img/elegant-age-verification-responsive-age-gate-plugin-for-wordpress.png3.25KB2.18KB▼ 32.95%
assets/img/elegant-elements-jquery-forms.png0.93KB0.94KB0.00%
assets/img/elegant-scroll-to-top-back-to-top-javascript-plugin.png1.78KB1.76KB▼ 0.88%
assets/minicolors/jquery.minicolors.png67.02KB34.31KB▼ 48.80%