68% rig-elements

Code Review | Rig Elements For Elementor

WordPress plugin Rig Elements For Elementor scored68%from 54 tests.

About plugin

  • Plugin page: rig-elements
  • Plugin version: 1.0
  • PHP compatiblity: 7.2+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.9-6.0.2
  • WordPress version: 6.3.1
  • First release: Oct 26, 2022
  • Latest release: Oct 26, 2022
  • Number of updates: 5
  • Update frequency: N/A
  • Top authors: asadabir (100%)

Code review

54 tests

User reviews

1 review

Install metrics

100+ active /363 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
Install script ran successfully

Server metrics [RAM: ▲0.03MB] [CPU: ▼7.36ms] Passed 4 tests

An overview of server-side resources used by Rig Elements For Elementor
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.61 ▲0.1542.47 ▼0.35
Dashboard /wp-admin3.32 ▲0.0155.31 ▲2.35
Posts /wp-admin/edit.php3.43 ▲0.0755.80 ▲9.31
Add New Post /wp-admin/post-new.php5.90 ▲0.0193.70 ▼30.87
Media Library /wp-admin/upload.php3.24 ▲0.0141.51 ▼0.58

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

Filesystem and database footprint
No storage issues were detected
Filesystem: 899 new files
Database: 1 new table, 6 new options
New tables
wp_rig_leads
New WordPress options
widget_recent-comments
widget_recent-posts
theysaidso_admin_options
db_upgraded
can_compress_scripts
widget_theysaidso_widget

Browser metrics Passed 4 tests

Rig Elements For Elementor: an overview of browser usage
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,832 ▲4613.25 ▼1.111.70 ▼0.1644.53 ▲0.59
Dashboard /wp-admin2,241 ▲385.85 ▲0.96104.96 ▼7.8139.60 ▼0.41
Posts /wp-admin/edit.php2,117 ▲202.02 ▼0.0338.94 ▲2.4233.68 ▼1.10
Add New Post /wp-admin/post-new.php1,557 ▲1723.48 ▲5.42589.81 ▼92.6056.56 ▼6.02
Media Library /wp-admin/upload.php1,417 ▲144.24 ▲0.02110.94 ▼7.4647.58 ▲0.25

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
It is recommended to fix the following
  • This plugin does not fully uninstall, leaving 1 table in the database
    • wp_rig_leads
  • This plugin does not fully uninstall, leaving 6 options in the database
    • widget_recent-posts
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • db_upgraded
    • can_compress_scripts
    • widget_recent-comments

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Good news, no errors were detected

SRP 0% from 2 tests

🔹 Tests weight: 20 | A shallow check of the single-responsibility principle; PHP files should perform no action - including output of placeholder text - and trigger no errors when accessed directly
The following issues need your attention
  • 1× PHP files perform the action of outputting non-empty strings when accessed directly:
    • > /wp-content/plugins/rig-elements/vendor/timber/timber/tests/assets/my-sidebar.php
  • 381× PHP files trigger errors when accessed directly with GET requests (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Class 'Twig\ode\ode' not found in wp-content/plugins/rig-elements/vendor/twig/twig/src/Node/FlushNode.php:21
    • > PHP Fatal error
      Uncaught Error: Class 'Composer\\Installers\\BaseInstaller' not found in wp-content/plugins/rig-elements/vendor/composer/installers/src/Composer/Installers/ModxInstaller.php:8
    • > PHP Fatal error
      Uncaught Error: Class 'Twig\\Extension\\AbstractExtension' not found in wp-content/plugins/rig-elements/vendor/twig/twig/src/Extension/ProfilerExtension.php:17
    • > PHP Fatal error
      Uncaught Error: Class 'Timber_UnitTestCase' not found in wp-content/plugins/rig-elements/vendor/timber/timber/tests/test-timber-image-resize.php:3
    • > PHP Fatal error
      Uncaught Error: Class 'Twig\ode\\Expression\\TestExpression' not found in wp-content/plugins/rig-elements/vendor/twig/twig/src/Node/Expression/Test/NullTest.php:24
    • > PHP Fatal error
      Uncaught Error: Class 'Twig_SimpleFunction' not found in wp-content/plugins/rig-elements/vendor/timber/timber/lib/Twig_Function.php:25
    • > PHP Fatal error
      Uncaught Error: Class 'Twig\ode\\Expression\\Unary\\AbstractUnary' not found in wp-content/plugins/rig-elements/vendor/twig/twig/src/Node/Expression/Unary/NotUnary.php:17
    • > PHP Fatal error
      Uncaught Error: Class 'Timber_UnitTestCase' not found in wp-content/plugins/rig-elements/vendor/timber/timber/tests/test-timber-post-preview.php:3
    • > PHP Fatal error
      Uncaught Error: Class 'Twig\\Extension\\AbstractExtension' not found in wp-content/plugins/rig-elements/vendor/twig/twig/src/Extension/EscaperExtension.php:18
    • > PHP Fatal error
      Uncaught Error: Class 'Timber_UnitTestCase' not found in wp-content/plugins/rig-elements/vendor/timber/timber/tests/test-timber-properties.php:3

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
There were no browser issues found

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 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
These attributes need your attention:
  • Screenshots: Add an image for screenshot #2 (Leads)
The official readme.txt might help

rig-elements/rig-elements.php 92% from 13 tests

Analyzing the main PHP file in "Rig Elements For Elementor" version 1.0
The following require your attention:
  • Description: If Twitter did it, so should we! Keep the description under 140 characters (currently 213 characters long)

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 detected52,185 lines of code in 842 files:
LanguageFilesBlank linesComment linesLines of code
PHP6819,69311,90145,202
Markdown461,38803,385
JSON11001,241
CSS513399664
YAML1211714541
Twig61430325
Bourne Shell35219287
PO File378101234
XML91951189
SVG40064
JavaScript6275743
reStructuredText18510

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.24
Average class complexity5.67
▷ Minimum class complexity1.00
▷ Maximum class complexity178.00
Average method complexity2.10
▷ Minimum method complexity1.00
▷ Maximum method complexity33.00
Code structure
Namespaces44
Interfaces19
Traits0
Classes644
▷ Abstract classes142.17%
▷ Concrete classes63097.83%
▷ Final classes538.41%
Methods2,846
▷ Static methods31511.07%
▷ Public methods2,50688.05%
▷ Protected methods2498.75%
▷ Private methods913.20%
Functions302
▷ Named functions17056.29%
▷ Anonymous functions13243.71%
Constants83
▷ Global constants1720.48%
▷ Class constants6679.52%
▷ Public constants6598.48%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
3 PNG files occupy 0.04MB with 0.02MB in potential savings
Potential savings
Compression of 3 random PNG files using pngquant
FileSize - originalSize - compressedSavings
vendor/timber/timber/tests/assets/cropper.png15.74KB0.31KB▼ 98.01%
vendor/timber/timber/tests/assets/eastern-trans.png12.34KB7.39KB▼ 40.11%
vendor/timber/timber/tests/assets/flag.png10.33KB4.00KB▼ 61.24%