Benchmarks
Plugin footprint 82% 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.05MB] [CPU: ▲3.33ms] 75% from 4 tests
Server-side resources used by Custom CSS and JavaScript
It is recommended to improve the following
- CPU: Total CPU usage should be kept under 500.00ms (currently 554.73ms on /wp-admin/themes.php?page=hm_custom_js)
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.52 ▲0.06 | 50.35 ▲9.69 |
Dashboard /wp-admin | 3.35 ▲0.05 | 53.61 ▲5.82 |
Posts /wp-admin/edit.php | 3.40 ▲0.04 | 48.99 ▲2.77 |
Add New Post /wp-admin/post-new.php | 5.93 ▲0.05 | 98.27 ▲3.86 |
Media Library /wp-admin/upload.php | 3.27 ▲0.05 | 32.47 ▲0.86 |
Custom JavaScript /wp-admin/themes.php?page=hm_custom_js | 3.30 | 554.73 |
Custom CSS /wp-admin/themes.php?page=hm_custom_css | 3.29 | 89.25 |
Server storage [IO: ▲0.82MB] [DB: ▲0.00MB] Passed 3 tests
Input-output and database impact of this plugin
No storage issues were detected
Filesystem: 63 new files
Database: no new tables, 7 new options
New WordPress options |
---|
widget_recent-posts |
theysaidso_admin_options |
widget_theysaidso_widget |
can_compress_scripts |
hm_custom_css_js_first_activate |
widget_recent-comments |
db_upgraded |
Browser metrics Passed 4 tests
Checking browser requirements for Custom CSS and JavaScript
There were no issues detected in relation to browser resource usage
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,837 ▲102 | 14.38 ▲0.01 | 2.08 ▼0.22 | 42.07 ▼7.91 |
Dashboard /wp-admin | 2,217 ▲32 | 5.83 ▼0.05 | 153.70 ▲36.03 | 59.42 ▲10.57 |
Posts /wp-admin/edit.php | 2,100 ▲8 | 1.97 ▼0.08 | 48.53 ▲8.01 | 35.34 ▲1.18 |
Add New Post /wp-admin/post-new.php | 1,548 ▲34 | 23.27 ▲5.39 | 653.31 ▼42.06 | 68.02 ▲2.29 |
Media Library /wp-admin/upload.php | 1,399 ▲20 | 4.22 ▲0.07 | 96.49 ▼7.61 | 44.99 ▼9.09 |
Custom JavaScript /wp-admin/themes.php?page=hm_custom_js | 1,749 | 2.57 | 56.86 | 181.44 |
Custom CSS /wp-admin/themes.php?page=hm_custom_css | 1,746 | 2.57 | 56.92 | 105.55 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests
🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
You still need to fix the following
- Zombie WordPress options were found after uninstall: 7 options
- db_upgraded
- theysaidso_admin_options
- widget_recent-posts
- widget_theysaidso_widget
- can_compress_scripts
- hm_custom_css_js_first_activate
- widget_recent-comments
Smoke tests 50% from 4 tests
Server-side errors 0% from 1 test
🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
These errors were triggered by the plugin
- 2 occurences, only the last one shown
- > GET request to /wp-admin/themes.php?page=hm_custom_css
- > Warning in wp-admin/includes/plugin.php+294
opendir(wp-content/plugins/ai-image-generator-lab): failed to open dir: No such file or directory
- 2 occurences, only the last one shown
- > GET request to /wp-admin/themes.php?page=hm_custom_css
- > Warning in wp-admin/includes/plugin.php+294
opendir(wp-content/plugins/wp-layouts): failed to open dir: No such file or directory
- 2 occurences, only the last one shown
- > GET request to /wp-admin/themes.php?page=hm_custom_css
- > Warning in wp-admin/includes/plugin.php+294
opendir(wp-content/plugins/product-sales-report-for-woocommerce): failed to open dir: No such file or directory
- 2 occurences, only the last one shown
- > GET request to /wp-admin/themes.php?page=hm_custom_css
- > Warning in wp-admin/includes/plugin.php+294
opendir(wp-content/plugins/export-order-items-for-woocommerce): failed to open dir: No such file or directory
- 2 occurences, only the last one shown
- > GET request to /wp-admin/themes.php?page=hm_custom_css
- > Warning in wp-admin/includes/plugin.php+294
opendir(wp-content/plugins/shortcodes-for-divi): failed to open dir: No such file or directory
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
The following issues need your attention
- 3× GET requests to PHP files have triggered server-side errors or warnings:
- > PHP Fatal error
Uncaught Error: Class 'MatthiasMullie\\Minify\\Minify' not found in wp-content/plugins/custom-css-and-javascript/minify/src/CSS.php:17
- > PHP Fatal error
Uncaught Error: Class 'MatthiasMullie\\Minify\\Minify' not found in wp-content/plugins/custom-css-and-javascript/minify/src/JS.php:15
- > PHP Fatal error
Uncaught Error: Call to undefined function add_action() in wp-content/plugins/custom-css-and-javascript/custom-css-and-javascript.php:32
- > PHP Fatal error
User-side errors Passed 1 test
🔹 Test weight: 20 | This is a shallow check for browser errors
There were no browser issues found
Optimizations
Plugin configuration Passed 29 tests
readme.txt Passed 16 tests
The readme.txt file uses markdown syntax to describe your plugin to the world
10 plugin tags: custom styles, stylesheet, custom javascript, custom js, custom stylesheet...
custom-css-and-javascript/custom-css-and-javascript.php Passed 13 tests
The primary PHP file in "Custom CSS and JavaScript" version 2.0.15 is used by WordPress to initiate all plugin functionality
65 characters long description:
Easily add custom CSS and JavaScript code to your WordPress site.
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | An overview of files in this plugin; executable files are not allowed
Good job! No executable or dangerous file extensions detected13,331 lines of code in 47 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
JavaScript | 12 | 1,070 | 1,047 | 9,639 |
CSS | 9 | 67 | 48 | 1,268 |
PHP | 10 | 330 | 834 | 1,136 |
Sass | 11 | 233 | 47 | 1,134 |
SVG | 5 | 0 | 1 | 154 |
PHP code Passed 2 tests
This is a very shot review of cyclomatic complexity and code structure
This plugin has no cyclomatic complexity issues
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.35 |
Average class complexity | 13.83 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 26.00 |
Average method complexity | 3.00 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 7.00 |
Code structure | ||
---|---|---|
Namespaces | 2 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 6 | |
▷ Abstract classes | 1 | 16.67% |
▷ Concrete classes | 5 | 83.33% |
▷ Final classes | 0 | 0.00% |
Methods | 42 | |
▷ Static methods | 3 | 7.14% |
▷ Public methods | 17 | 40.48% |
▷ Protected methods | 25 | 59.52% |
▷ Private methods | 0 | 0.00% |
Functions | 21 | |
▷ Named functions | 17 | 80.95% |
▷ Anonymous functions | 4 | 19.05% |
Constants | 3 | |
▷ Global constants | 1 | 33.33% |
▷ Class constants | 2 | 66.67% |
▷ Public constants | 2 | 100.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
2 compressed PNG files occupy 0.03MB
Potential savings
Compression of 2 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
images/wp_zone_logo.png | 2.01KB | 2.14KB | 0.00% |
images/ai-image-lab-images.png | 27.39KB | 28.86KB | 0.00% |