Magento 2.0.18 is the final 2.0.x release. After March 2018, Magento 2.0.x will no longer receive security patches, quality fixes, or documentation updates.
To maintain your site's performance, security, and PCI compliance, upgrade to the latest version of Magento.

PHP coding standard

The Magento core development team uses the PSR-1: Basic Coding Standard and PSR-2: Coding Style Guide. Magento recommends that developers who create Magento extensions and customizations also use these standards.

Where possible, use PHP_CodeSniffer to automatically enforce these standards. Otherwise, you must apply these standards and requirements through rigorous code review.

Class name resolution standard

For class name resolution, use the ::class keyword instead of a string literal for every class name reference outside of that class. This includes references to:

  • Fully qualified class name
  • Imported/non-imported class name
  • Namespace relative class name
  • Import relative class name