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
Install script ran successfully
Server metrics [RAM: ▼0.21MB] [CPU: ▼16.97ms] Passed 4 tests
Analyzing server-side resources used by Lightweight JS Snippet
This plugin does not affect your website's performance
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.48 ▲0.02 | 42.95 ▲3.34 |
Dashboard /wp-admin | 3.08 ▼0.22 | 29.11 ▼25.28 |
Posts /wp-admin/edit.php | 3.22 ▼0.14 | 35.55 ▼17.27 |
Add New Post /wp-admin/post-new.php | 5.46 ▼0.43 | 82.30 ▼18.89 |
Media Library /wp-admin/upload.php | 3.17 ▼0.06 | 29.32 ▼6.42 |
Lightweight JS snippet /wp-admin/options-general.php?page=jhljs-settings | 3.23 | 33.16 |
Server storage [IO: ▲0.01MB] [DB: ▲0.00MB] Passed 3 tests
Filesystem and database footprint
There were no storage issued detected upon installing this plugin
Filesystem: 4 new files
Database: no new tables, 6 new options
New WordPress options |
---|
db_upgraded |
widget_recent-posts |
can_compress_scripts |
widget_recent-comments |
widget_theysaidso_widget |
theysaidso_admin_options |
Browser metrics Passed 4 tests
This is an overview of browser requirements for Lightweight JS Snippet
This plugin renders optimally with no browser resource issues detected
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,793 ▲7 | 14.38 ▲0.86 | 1.84 ▼3.18 | 45.09 ▼1.71 |
Dashboard /wp-admin | 2,202 ▲41 | 5.57 ▼0.02 | 88.81 ▼15.71 | 40.96 ▼6.20 |
Posts /wp-admin/edit.php | 2,101 ▼2 | 1.97 ▲0.03 | 35.60 ▼4.21 | 32.96 ▼8.53 |
Add New Post /wp-admin/post-new.php | 1,529 ▲3 | 23.37 ▼0.28 | 675.70 ▲49.04 | 55.31 ▲0.88 |
Media Library /wp-admin/upload.php | 1,401 ▲1 | 4.21 ▼0.00 | 101.67 ▼3.78 | 43.97 ▼0.47 |
Lightweight JS snippet /wp-admin/options-general.php?page=jhljs-settings | 987 | 3.46 | 78.12 | 40.65 |
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
Please fix the following items
- Zombie WordPress options were found after uninstall: 6 options
- can_compress_scripts
- db_upgraded
- widget_recent-comments
- widget_theysaidso_widget
- widget_recent-posts
- theysaidso_admin_options
Smoke tests Passed 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
The smoke test was a success, however most plugin functionality was not tested
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
No output text or server-side errors detected on direct access of PHP files
User-side errors Passed 1 test
🔹 Test weight: 20 | A shallow check that no browser errors were triggered
No browser errors were detected
Optimizations
Plugin configuration Passed 29 tests
readme.txt Passed 16 tests
Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
3 plugin tags: snippet, insert on one page, javascript
lightweight-js-snippet/lightweight-js-snippet.php Passed 13 tests
The principal PHP file in "Lightweight JS Snippet" v. 1.2 is loaded by WordPress automatically on each request
43 characters long description:
Add JS scipt to one or more pages or posts.
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 detected126 lines of code in 3 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 2 | 37 | 42 | 108 |
JavaScript | 1 | 2 | 0 | 18 |
PHP code Passed 2 tests
Analyzing logical lines of code, cyclomatic complexity, and other code metrics
This plugin has no cyclomatic complexity problems
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.19 |
Average class complexity | 5.00 |
▷ Minimum class complexity | 5.00 |
▷ Maximum class complexity | 5.00 |
Average method complexity | 2.33 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 4.00 |
Code structure | ||
---|---|---|
Namespaces | 1 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 1 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 1 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 3 | |
▷ Static methods | 1 | 33.33% |
▷ Public methods | 2 | 66.67% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 1 | 33.33% |
Functions | 7 | |
▷ Named functions | 6 | 85.71% |
▷ Anonymous functions | 1 | 14.29% |
Constants | 0 | |
▷ Global constants | 0 | 0.00% |
▷ Class constants | 0 | 0.00% |
▷ Public constants | 0 | 0.00% |
Plugin size Passed 2 tests
Image compression Passed 2 tests
Often times overlooked, PNG files can occupy unnecessary space in your plugin
No PNG files were detected