99% amp-html-sitemap

Code Review | AMP HTML Sitemap

WordPress plugin AMP HTML Sitemap scored 99% from 54 tests.

About plugin

  • Plugin page: amp-html-sitemap
  • Plugin version: 2.3
  • PHP version: 7.4.16
  • WordPress compatibility: 4.5.3-4.6.1
  • WordPress version: 5.8.1
  • First release: Jul 4, 2016
  • Latest release: Dec 20, 2016
  • Number of updates: 58
  • Update frequency: every 2.9 days
  • Top authors: nmvdvjr (100%)

Code review

54 tests

User reviews

2 reviews

Install metrics

200+ active / 5,252 total downloads

Benchmarks

Plugin footprint Passed 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
This plugin's installer ran successfully

Server metrics [RAM: ▼0.00MB] [CPU: ▼180.94ms] Passed 4 tests

Server-side resources used by AMP HTML Sitemap
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /2.85 ▲0.0128.33 ▲2.45
Dashboard /wp-admin3.07 ▲0.0037.45 ▼4.66
Posts /wp-admin/edit.php3.12 ▲0.0132.15 ▼0.52
Add New Post /wp-admin/post-new.php5.43 ▼0.0177.78 ▼717.12
Media Library /wp-admin/upload.php3.01 ▲0.0024.23 ▼1.44

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

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

Browser metrics Passed 4 tests

A check of browser resources used by AMP HTML Sitemap
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,666 ▲6515.71 ▲0.115.71 ▲0.3681.28 ▲9.82
Dashboard /wp-admin2,933 ▲416.15 ▼0.01114.52 ▼15.69164.27 ▼6.08
Posts /wp-admin/edit.php2,743 ▼03.35 ▼0.0162.74 ▲1.05145.40 ▼1.04
Add New Post /wp-admin/post-new.php3,815 ▲11718.96 ▲0.62421.27 ▼18.81167.69 ▲3.83
Media Library /wp-admin/upload.php1,749 ▼35.47 ▼0.08141.66 ▲0.94180.91 ▼3.32

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] Passed 4 tests

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
Uninstall script ran successfully

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
The smoke test was a success, however most plugin functionality was not tested

SRP Passed 2 tests

🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
No output text or server-side errors detected on direct access of PHP files

User-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
No browser errors were detected

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 94% from 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
These attributes need to be fixed: You can look at the official readme.txt

amp-html-sitemap/AMP HTML Sitemap.php 85% from 13 tests

This is the main PHP file of "AMP HTML Sitemap" version 2.3, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
Please make the necessary changes and fix the following:
  • Main file name: Name the main plugin file the same as the plugin slug ("amp-html-sitemap.php" instead of "AMP HTML Sitemap.php")
  • Description: Please keep the plugin description shorter than 140 characters (currently 166 characters long)

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of programming languages used in this plugin; dangerous file extensions are not allowed
Good job! No executable or dangerous file extensions detected26 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP117826

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.15
Average class complexity0.00
▷ Minimum class complexity0.00
▷ Maximum class complexity0.00
Average method complexity0.00
▷ Minimum method complexity0.00
▷ Maximum method complexity0.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes0
▷ Abstract classes00.00%
▷ Concrete classes00.00%
▷ Final classes00.00%
Methods0
▷ Static methods00.00%
▷ Public methods00.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions2
▷ Named functions2100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
No PNG images were found in this plugin