coding-standards
Here are 192 public repositories matching this topic...
-
Updated
Jun 24, 2020 - PHP
I don't think it is correct to generate code which will put an argument with a default value before an argument without a default value.
In the example the generated code produces a function like that:
function bar(int $a = null, string $b, bool $c, callable $d = null) : float
This means the first argument is optional, but the second and third aren't.
I realise = null
i
Nice! Please add the following to README.md to make Laravel the default standard.
Link (or copy) Laravel into the global CodeSniffer directory.
Mac OSX Homebrew example:
ln -s LaravelCodeSniffer/Standards/Laravel/ /usr/local/etc/php-code-sniffer/Standards/
Set Laravel as default:
phpcs --config-set default_standard Laravel
Details at https://github.com/squizlabs/PHP_CodeSniffer/wiki/Conf
-
Updated
May 11, 2020 - PHP
https://github.com/stevegrunwell/wp-enforcer/blob/develop/bin/hooks/pre-commit#L9
This line is hard-coded and does not respect the -c
flag of the CLI.
# Determine if we have a phpcs.xml file
if [[ -f ./phpcs.xml ]]; then
standard="--standard=./phpcs.xml"
else
standard=''
fi
The above needs to be updated to accept an arg when -c
is set in the CLI.
-
Updated
Feb 14, 2020 - PHP
-
Updated
Apr 29, 2019 - C#
-
Updated
Sep 10, 2017 - Shell
Prefer single quotes
- More JavaScript teams do this (e.g. airbnb, standard, npm, node, google/angular, facebook/react, prettier).
- It's easier to type (no shift needed on most keyboards).
- Allows easier write html within javascript
- Single quotes can often look better when you're using them to represent an empty string '' vs "" (too many little marks in the latter and can be difficult read)
-
Updated
Apr 17, 2020 - PHP
-
Updated
Jun 5, 2020 - PHP
Issue Overview
When requesting a report for a specific version of a plugin, if Tide doesn't yet have a report for it it'll start to generate one and return a <p>pending</p>
response.
That response then gets cached, and will return the <p>pending</p>
response until it expires.
Suffixing a ?1
to the URL to bypass the URL caching then results in being able to access it.
Steps to R
-
Updated
Nov 28, 2019 - HTML
-
Updated
Feb 25, 2016 - JavaScript
Enhance readme
Add code examples for each sniff.Done- Show how to run individual sniffs or exclude individual sniffs.
- For each sniff show how to customize if applicable.
- Explain why, benefits of why you'd want each sniff.
-
Updated
Jan 7, 2019
-
Updated
Mar 7, 2019 - JavaScript
-
Updated
Oct 14, 2019 - C++
-
Updated
Jul 9, 2019 - Java
-
Updated
Apr 15, 2020 - JavaScript
-
Updated
Mar 16, 2020 - TypeScript
Remove scipy from How To Create Development Environments step 4 "Add dependencies" in doc/how_to_sprint.rst That is, only install numpy (specific version) as a dependency.
-
Updated
Jan 30, 2018
-
Updated
Jan 2, 2019
-
Updated
Nov 14, 2017 - PHP
-
Updated
Jun 25, 2020 - Java
Improve this page
Add a description, image, and links to the coding-standards topic page so that developers can more easily learn about it.
Add this topic to your repo
To associate your repository with the coding-standards topic, visit your repo's landing page and select "manage topics."
One thing that's super useful for new users is code examples. Right now, the biggest problem for someone to start using PHP_CodeSniffer is lack of a list of available Sniffers with their options and examples. From what I know to get a list of all sniffs right now, you have to go through source code in
src/Standards
, and it's exhausting. Something like [mlocati/phpPHP-cs-fixer-configurator
](htt