mirror of
https://github.com/RSS-Bridge/rss-bridge.git
synced 2025-03-15 04:31:16 +03:00
Created Whitespace (markdown)
parent
3ec95eaa30
commit
65fe2db5a9
1 changed files with 27 additions and 0 deletions
27
Whitespace.md
Normal file
27
Whitespace.md
Normal file
|
@ -0,0 +1,27 @@
|
|||
# Do not add a whitespace before a semicolon
|
||||
|
||||
A semicolon indicates the end of a line of code. Spaces before the semicolon is unnecessary and must be removed.
|
||||
|
||||
<details><summary>Example</summary><div><br>
|
||||
|
||||
**Bad**
|
||||
|
||||
```PHP
|
||||
echo 'Hello World!' ;
|
||||
```
|
||||
|
||||
**Good**
|
||||
|
||||
```PHP
|
||||
echo 'Hello World!';
|
||||
```
|
||||
|
||||
</div></details><br>
|
||||
|
||||
_Reference_: [`Squiz.WhiteSpace.SemicolonSpacing`](https://github.com/squizlabs/PHP_CodeSniffer/blob/master/src/Standards/Squiz/Sniffs/WhiteSpace/SemicolonSpacingSniff.php)
|
||||
|
||||
# Do not add whitespace at start or end of a file or end of a line
|
||||
|
||||
Whitespace at the end of lines or at the start or end of a file is invisible to the reader and absolutely unnecessary. Thus it must be removed.
|
||||
|
||||
_Reference_: [`Squiz.WhiteSpace.SuperfluousWhitespace`](https://github.com/squizlabs/PHP_CodeSniffer/blob/master/src/Standards/Squiz/Sniffs/WhiteSpace/SuperfluousWhitespaceSniff.php)
|
Loading…
Add table
Reference in a new issue