Warning: DOMDocument::loadHTML(): Tag template invalid in Entity, line: 12 in /home/customer/www/salferrarello.com/public_html/wp-content/plugins/gistpress/includes/class-gistpress.php on line 466
Warning: DOMDocument::loadHTML(): Tag svg invalid in Entity, line: 14 in /home/customer/www/salferrarello.com/public_html/wp-content/plugins/gistpress/includes/class-gistpress.php on line 466
Warning: DOMDocument::loadHTML(): Tag path invalid in Entity, line: 15 in /home/customer/www/salferrarello.com/public_html/wp-content/plugins/gistpress/includes/class-gistpress.php on line 466
Warning: DOMDocument::loadHTML(): Tag template invalid in Entity, line: 27 in /home/customer/www/salferrarello.com/public_html/wp-content/plugins/gistpress/includes/class-gistpress.php on line 466
Warning: DOMDocument::loadHTML(): Tag svg invalid in Entity, line: 29 in /home/customer/www/salferrarello.com/public_html/wp-content/plugins/gistpress/includes/class-gistpress.php on line 466
Warning: DOMDocument::loadHTML(): Tag path invalid in Entity, line: 30 in /home/customer/www/salferrarello.com/public_html/wp-content/plugins/gistpress/includes/class-gistpress.php on line 466
The editorconfig project allows you to standardize general coding standards on a project.
I was working on a project where I needed to follow the PHP PSR-2 standard. This is the .editorconfig
file I used.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# EditorConfig helps keep your project formatting consistent. | |
# See https://EditorConfig.org | |
# | |
# PHP PSR-2 Coding Standards | |
# http://www.php-fig.org/psr/psr-2/ | |
# | |
# Author: Sal Ferrarello (@salcode) | |
# | |
# You can download this file directly | |
# to your project from the command-line with | |
# curl -O https://gist.githubusercontent.com/salcode/18eaa8cfa3b097da2f58b582197906d7/raw/.editorconfig | |
root = true | |
[*] | |
charset = utf-8 | |
end_of_line = lf | |
insert_final_newline = true | |
trim_trailing_whitespace = true | |
indent_style = space | |
indent_size = 2 | |
[*.php] | |
indent_size = 4 | |
[*.md] | |
trim_trailing_whitespace = false |
For WordPress projects, I use my WordPress .editorconfig.
Leave a Reply