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.02MB] [CPU: ▼135.67ms] Passed 4 tests
A check of server-side resources used by PDF Viewer for Elementor
This plugin has minimal impact on server resources
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 2.86 ▲0.14 | 35.04 ▲14.56 |
Dashboard /wp-admin | 3.08 ▲0.03 | 47.34 ▲3.79 |
Posts /wp-admin/edit.php | 3.13 ▲0.03 | 47.02 ▼4.07 |
Add New Post /wp-admin/post-new.php | 5.45 ▲0.02 | 95.02 ▼543.68 |
Media Library /wp-admin/upload.php | 3.03 ▲0.02 | 32.66 ▲1.28 |
Server storage [IO: ▲11.79MB] [DB: ▲0.00MB] Passed 3 tests
A short overview of filesystem and database impact
The plugin installed successfully
Filesystem: 386 new files
Database: no new tables, 1 new option
New WordPress options |
---|
pdf_elementor_activation_time |
Browser metrics Passed 4 tests
Checking browser requirements for PDF Viewer for Elementor
There were no issues detected in relation to browser resource usage
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 3,725 ▲129 | 16.30 ▲0.77 | 7.66 ▼0.52 | 49.32 ▼3.95 |
Dashboard /wp-admin | 2,992 ▲59 | 6.04 ▲0.10 | 141.32 ▼10.67 | 114.00 ▼8.73 |
Posts /wp-admin/edit.php | 2,762 ▲23 | 2.70 ▲0.01 | 64.72 ▼5.33 | 90.50 ▼5.86 |
Add New Post /wp-admin/post-new.php | 1,610 ▼62 | 18.82 ▼0.06 | 390.86 ▲8.03 | 109.43 ▼3.05 |
Media Library /wp-admin/upload.php | 1,830 ▲23 | 5.02 ▲0.01 | 156.79 ▼0.30 | 127.84 ▲7.49 |
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
- This plugin does not fully uninstall, leaving 1 option in the database
- pdf_elementor_activation_time
Smoke tests 75% from 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | A smoke test targeting server-side errors
The smoke test was a success, however most plugin functionality was not tested
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
Almost there! Just fix the following items
- 1× PHP files trigger errors when accessed directly with GET requests:
- > PHP Fatal error
Uncaught Error: Call to undefined function ElementorPDFViewer\\add_action() in wp-content/plugins/pdf-viewer-for-elementor/plugin.php:82
- > PHP Fatal error
User-side errors Passed 1 test
🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
Everything seems fine on the user side
Optimizations
Plugin configuration 93% from 29 tests
readme.txt Passed 16 tests
The readme.txt file is an important file in your plugin as it is parsed by WordPress.org to prepare the public listing of your plugin
5 plugin tags: pdf, elementor widget, elements, elementor, viewer
pdf-viewer-for-elementor/index.php 85% from 13 tests
The main PHP file in "PDF Viewer for Elementor" ver. 2.9.3 adds more information about the plugin and also serves as the entry point for this plugin
You should first fix the following items:
- Text Domain: The text domain is optional since WordPress version 4.6; if you do specify it, it must be the same as the plugin slug
- Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("pdf-viewer-for-elementor.php" instead of "index.php")
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
Success! There were no dangerous files found in this plugin88,210 lines of code in 20 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
JavaScript | 4 | 13,447 | 978 | 85,153 |
CSS | 1 | 294 | 37 | 2,132 |
PHP | 4 | 102 | 278 | 420 |
HTML | 1 | 47 | 16 | 331 |
SVG | 9 | 0 | 0 | 150 |
Markdown | 1 | 12 | 0 | 24 |
PHP code Passed 2 tests
This is a short overview of cyclomatic complexity and code structure for this plugin
This plugin has no cyclomatic complexity issues
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.31 |
Average class complexity | 6.00 |
▷ Minimum class complexity | 2.00 |
▷ Maximum class complexity | 9.00 |
Average method complexity | 1.91 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 9.00 |
Code structure | ||
---|---|---|
Namespaces | 2 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 4 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 4 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 22 | |
▷ Static methods | 1 | 4.55% |
▷ Public methods | 17 | 77.27% |
▷ Protected methods | 4 | 18.18% |
▷ Private methods | 1 | 4.55% |
Functions | 4 | |
▷ Named functions | 4 | 100.00% |
▷ Anonymous functions | 0 | 0.00% |
Constants | 3 | |
▷ Global constants | 0 | 0.00% |
▷ Class constants | 3 | 100.00% |
▷ Public constants | 3 | 100.00% |
Plugin size Passed 2 tests
Image compression Passed 2 tests
It is recommended to compress PNG files in your plugin to minimize bandwidth usage
86 compressed PNG files occupy 0.05MB
Potential savings
Compression of 5 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
assets/pdfjs/web/images/treeitem-collapsed.png | 0.13KB | 0.21KB | 0.00% |
assets/pdfjs/web/images/toolbarButton-viewOutline-rtl@2x.png | 0.38KB | 0.60KB | 0.00% |
assets/pdfjs/web/images/toolbarButton-pageUp.png | 0.24KB | 0.37KB | 0.00% |
assets/pdfjs/web/images/findbarButton-previous-rtl@2x.png | 0.29KB | 0.47KB | 0.00% |
assets/pdfjs/web/images/secondaryToolbarButton-spreadOdd@2x.png | 0.61KB | 0.72KB | 0.00% |