coding-standards
coding-standards copied to clipboard
Human Made coding standards for modern code
[@tfrommen suggested in another PR that we regenerate the `package-lock.json` to use version 2 as a separate Pull Request to keep the size of the change down. ](https://github.com/humanmade/coding-standards/pull/275#discussion_r809226824) One thing...
We are using `npm-package-json-lint` to check that our package.json files comply with certain rules. One of these rules is configured so that you are not allowed to use `devDependencies` in...
This contribute towards #274 by upgrading the official WP package used for configuration and upgrading stylelint to 14.2 which was required by the WP package update. This fixes some deprecation...
Add some basic tests for styles. Follows similar setup to eslint tests. Can increase coverage in future. @tomjn Already did a PR for updating to the latest config already: https://github.com/humanmade/coding-standards/pull/275....
The create-react-app eslint configuration which we extend is the source of many of our peer dependency errors. We need to categorically overhaul and update our peer deps, but for now,...
This change means later versions of PHPCS 3.x can be used, rather than just 3.5. Version 3.7 is required for the sniffs to run on PHP 8.1 without triggering deprecated...
Fatal error is being thrown by `phpcs`. Reported in https://github.com/squizlabs/PHP_CodeSniffer/issues/3196, determined to be a WPCS error and fixed here https://github.com/WordPress/WordPress-Coding-Standards/commit/7cd46bed1e6a7a2af3fe24c7f4a044da3076d8f4 **Suggested resolution:** bump WPCS to latest (2.3.0) **Workaround:** You can...
``` npm WARN deprecated @stylelint/[email protected]: Use the original unforked package instead: postcss-markdown npm WARN deprecated [email protected]: This package has been deprecated, please use @wordpress/stylelint-config or @wordpress/scripts ``` There may be...
Unescaped output from WordPress translation functions is not being flagged by the full HM standards checks. The `HM-Minimum` standard allows the use of unescaped translation functions (see [HM-Minimum/ruleset.xml#L57-L66](https://github.com/humanmade/coding-standards/blob/f73d9dc587242fa2dbe3f1889ee3cfea17afc13a/HM-Minimum/ruleset.xml#L57-L66)). The minimum...
The following wil trigger a warning: `Using target="_blank" without rel="noopener noreferrer" is a security risk: see https://mathiasbynens.github.io/rel-noopener` ``` link text ``` However, checking the MDN docs, ( https://developer.mozilla.org/en-US/docs/Web/HTML/Link_types/noreferrer ), we...