84% wp-emmet

Code Review | WP Emmet

WordPress plugin WP Emmet scored84%from 54 tests.

About plugin

  • Plugin page: wp-emmet
  • Plugin version: 0.3.4
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-4.1
  • WordPress version: 6.3.1
  • First release: Jan 28, 2013
  • Latest release: Feb 24, 2015
  • Number of updates: 26
  • Update frequency: every 29.2 days
  • Top authors: rewish (100%)

Code review

54 tests

User reviews

10 reviews

Install metrics

3,000+ active /18,802 total downloads


Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
The plugin installed successfully, without throwing any errors or notices

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

An overview of server-side resources used by WP Emmet
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.50 ▲0.0438.93 ▼1.60
Dashboard /wp-admin3.34 ▼0.0045.84 ▼13.13
Posts /wp-admin/edit.php3.39 ▲0.0443.19 ▼4.89
Add New Post /wp-admin/post-new.php5.94 ▲0.0679.05 ▼22.83
Media Library /wp-admin/upload.php3.27 ▲0.0433.43 ▲0.59
Emmet /wp-admin/options-general.php?page=wp-emmet3.3231.24

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

Input-output and database impact of this plugin
This plugin installed successfully
Filesystem: 49 new files
Database: no new tables, 8 new options
New WordPress options

Browser metrics Passed 4 tests

A check of browser resources used by WP Emmet
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,821 ▲7513.71 ▼0.801.66 ▼0.1344.53 ▲4.03
Dashboard /wp-admin2,230 ▲395.53 ▲0.64116.05 ▲14.3741.01 ▼1.33
Posts /wp-admin/edit.php2,109 ▲202.36 ▲0.3536.43 ▼4.4334.27 ▼1.32
Add New Post /wp-admin/post-new.php1,530 ▲1117.91 ▼5.37671.93 ▲6.7636.47 ▼13.66
Media Library /wp-admin/upload.php1,409 ▲274.76 ▲0.5699.89 ▲1.8842.26 ▼5.21
Emmet /wp-admin/options-general.php?page=wp-emmet1,4652.3726.1926.27

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
These items require your attention
  • This plugin did not uninstall successfully, leaving 8 options in the database
    • can_compress_scripts
    • widget_recent-posts
    • widget_theysaidso_widget
    • db_upgraded
    • wp-emmet-migration-version
    • wp-emmet
    • theysaidso_admin_options
    • widget_recent-comments

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Good news, no errors were detected

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
  • 6× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Using $this when not in object context in wp-content/plugins/wp-emmet/views/options.php:1
    • > PHP Fatal error
      Uncaught Error: Using $this when not in object context in wp-content/plugins/wp-emmet/views/apply_for_textarea.php:3
    • > PHP Fatal error
      Uncaught Error: Using $this when not in object context in wp-content/plugins/wp-emmet/views/apply_for_codemirror.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/wp-emmet/WP/Emmet/Lang.php:10
    • > PHP Fatal error
      Uncaught Error: Call to undefined function __() in wp-content/plugins/wp-emmet/langs/fake.php:5
    • > PHP Warning
      Use of undefined constant WP_PLUGIN_DIR - assumed 'WP_PLUGIN_DIR' (this will throw an Error in a future version of PHP) in wp-content/plugins/wp-emmet/wp-emmet.php on line 13

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Everything seems fine on the user side


Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
Please fix the following attributes:
  • Plugin Name: "Plugin Name" should be replaced with the name of your plugin on the first line ( === wp-emmet === )
The official readme.txt might help

wp-emmet/wp-emmet.php Passed 13 tests

The main PHP script in "WP Emmet" version 0.3.4 is automatically included on every request by WordPress
36 characters long description:
Emmet (ex-Zen Coding) for WordPress.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are not allowed as they can serve as attack vectors
No dangerous file extensions were detected24,118 lines of code in 46 files:
LanguageFilesBlank linesComment linesLines of code
PO File15151118

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.18
Average class complexity6.11
▷ Minimum class complexity1.00
▷ Maximum class complexity17.00
Average method complexity1.78
▷ Minimum method complexity1.00
▷ Maximum method complexity7.00
Code structure
▷ Abstract classes00.00%
▷ Concrete classes9100.00%
▷ Final classes00.00%
▷ Static methods813.56%
▷ Public methods5389.83%
▷ Protected methods610.17%
▷ Private methods00.00%
▷ Named functions00.00%
▷ Anonymous functions00.00%
▷ Global constants583.33%
▷ Class constants116.67%
▷ Public constants1100.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
No PNG files were detected