Customize Formatting#
Respecting specific coding guidelines is crucial for maintaining a consistent codebase. In case the Code Style does not fit your needs, you can customize specific formatting rules.
The settings bellow override behaviour set with the "php.format.codestyle" setting.
- Settings:
php.format.rules.* - License: PREMIUM.
Customize Settings in VS Code Settings UI#

Browse through all the custom rules in Visual Studio Code Settings UI. Open command palette (Ctrl+Shift+P) and type Preferences: Open User Settings (UI). Then search for php.format and you will see all the available settings, including examples.
Indentation#
IndentBraces: Gets value indicating whether to indent braces
- setting:
php.format.rules.indentBraces - .editorconfig directive:
php_format_indent_braces
| |
| true | false |
Spacing#
Space after cast: Insert a space after a cast operator.
- setting:
php.format.rules.spaceAfterCast - .editorconfig directive:
php_format_space_after_cast - .editorconfig alternative directive:
ij_php_space_after_type_cast
| |
| true | false |
Space after unary not !: Insert a space after a unary not operator.
- setting:
php.format.rules.spaceAfterUnaryNot - .editorconfig directive:
php_format_space_after_unary_not - .editorconfig alternative directive:
ij_php_space_after_unary_not
| |
| true | false |
Space around concatenation .: Insert a space around concatenation operator.
- setting:
php.format.rules.spaceAroundConcatenation - .editorconfig directive:
php_format_space_around_concatenation - .editorconfig alternative directive:
ij_php_concat_spaces
| |
| true | false |
Space before colon : in control flow statements: Insert a space before colon in control flow blocks.
- setting:
php.format.rules.spaceBeforeColonInControlStatements - .editorconfig directive:
php_format_space_before_colon_in_control_statements
| |
| true | false |
Space before colon : in return type: Insert a space before colon in a return type
- setting:
php.format.rules.spaceBeforeColonInReturnType - .editorconfig directive:
php_format_space_before_colon_in_return_type - .editorconfig alternative directive:
ij_php_space_before_colon_in_return_type
| |
| true | false |
Space before parentheses in arrow functions: Insert a space before arrow function parentheses.
- setting:
php.format.rules.spaceBeforeParenthesesInArrowFunctions - .editorconfig directive:
php_format_space_before_parentheses_in_arrow_functions - .editorconfig alternative directive:
ij_php_space_before_short_closure_left_parenthesis
| |
| true | false |
Space before parentheses in function calls: Insert a space before parentheses in method, function and constructor call parentheses.
- setting:
php.format.rules.spaceBeforeParenthesesInCalls - .editorconfig directive:
php_format_space_before_parentheses_in_calls - .editorconfig alternative directive:
ij_php_space_before_method_call_parentheses
| |
| true | false |
Space before parentheses in control statements: Insert a space before parentheses in control statements.
- setting:
php.format.rules.spaceBeforeParenthesesInControlStatements - .editorconfig directive:
php_format_space_before_parentheses_in_control_statements - .editorconfig alternative directive:
ij_php_space_before_catch_parentheses
| |
| true | false |
Space before parentheses in declarations: Insert a space before parentheses in method, function and constructor declaration parentheses.
- setting:
php.format.rules.spaceBeforeParenthesesInDeclarations - .editorconfig directive:
php_format_space_before_parentheses_in_declarations - .editorconfig alternative directive:
ij_php_space_before_method_parentheses
| |
| true | false |
Space before unary not !: Insert a space before a unary not operator.
- setting:
php.format.rules.spaceBeforeUnaryNot - .editorconfig directive:
php_format_space_before_unary_not - .editorconfig alternative directive:
ij_php_space_before_unary_not
| |
| true | false |
Space within array initializer parentheses: Insert a space within array initializer parentheses.
- setting:
php.format.rules.spaceWithinArrayInitilizersParens - .editorconfig directive:
php_format_space_within_array_initilizers_parens - .editorconfig alternative directive:
ij_php_spaces_within_array_initializer_braces
| |
| true | false |
Space within brackets []: Insert a space within brackets.
- setting:
php.format.rules.spaceWithinBrackets - .editorconfig directive:
php_format_space_within_brackets - .editorconfig alternative directive:
ij_php_spaces_within_brackets
| |
| true | false |
Space within brackets [] around expression: Insert a space within brackets around expression.
- setting:
php.format.rules.spaceWithinBracketsAroundExpression - .editorconfig directive:
php_format_space_within_brackets_around_expression - .editorconfig alternative directive:
ij_php_spaces_around_var_within_brackets
| |
| true | false |
Space within call parentheses: Insert a space within method, function and constructor call parentheses.
- setting:
php.format.rules.spaceWithinCallParens - .editorconfig directive:
php_format_space_within_call_parens - .editorconfig alternative directive:
ij_php_spaces_within_method_call_parentheses
| |
| true | false |
Space within catch parentheses: Insert a space within catch statement header parentheses.
- setting:
php.format.rules.spaceWithinCatchParens - .editorconfig directive:
php_format_space_within_catch_parens - .editorconfig alternative directive:
ij_php_spaces_within_catch_parentheses
| |
| true | false |
Space within declaration parentheses: Insert a space within method, function and constructor declaration parentheses.
- setting:
php.format.rules.spaceWithinDeclParens - .editorconfig directive:
php_format_space_within_decl_parens - .editorconfig alternative directive:
ij_php_spaces_within_method_parentheses
| |
| true | false |
Space within parentheses around expression: Insert a space within parentheses around expression.
- setting:
php.format.rules.spaceWithinExpressionParens - .editorconfig directive:
php_format_space_within_expression_parens - .editorconfig alternative directive:
ij_php_spaces_within_parentheses
| |
| true | false |
Space within for parentheses: Insert a space within for statement header parentheses.
- setting:
php.format.rules.spaceWithinForParens - .editorconfig directive:
php_format_space_within_for_parens - .editorconfig alternative directive:
ij_php_spaces_within_for_parentheses
| |
| true | false |
Space within foreach parentheses: Insert a space within foreach statement header parentheses.
- setting:
php.format.rules.spaceWithinForeachParens - .editorconfig directive:
php_format_space_within_foreach_parens
| |
| true | false |
Space within if parentheses: Insert a space within if statement header parentheses.
- setting:
php.format.rules.spaceWithinIfParens - .editorconfig directive:
php_format_space_within_if_parens - .editorconfig alternative directive:
ij_php_spaces_within_if_parentheses
| |
| true | false |
Space within switch parentheses: Insert a space within switch statement header parentheses.
- setting:
php.format.rules.spaceWithinSwitchParens - .editorconfig directive:
php_format_space_within_switch_parens
| |
| true | false |
Space within while parentheses: Insert a space within while statement header parentheses.
- setting:
php.format.rules.spaceWithinWhileParens - .editorconfig directive:
php_format_space_within_while_parens - .editorconfig alternative directive:
ij_php_spaces_within_while_parentheses
| |
| true | false |
NewLines#
catch on a new line: Place catch on a new line.
- setting:
php.format.rules.catchOnNewLine - .editorconfig directive:
php_format_catch_on_new_line - .editorconfig alternative directive:
ij_php_catch_on_new_line
| |
| true | false |
else on a new line: Place else on a new line.
- setting:
php.format.rules.elseOnNewLine - .editorconfig directive:
php_format_else_on_new_line - .editorconfig alternative directive:
ij_php_else_on_new_line
| |
| true | false |
Insert final newline: Inserts final newline at the end of a file.
- setting:
php.format.rules.endWithNewLine - .editorconfig directive:
php_format_end_with_new_line
finally on a new line: Place finally on a new line.
- setting:
php.format.rules.finallyOnNewLine - .editorconfig directive:
php_format_finally_on_new_line - .editorconfig alternative directive:
ij_php_finally_on_new_line
| |
| true | false |
Open brace on a new line for anonymous classes: Place open brace { on a new line for anonymous classes.
- setting:
php.format.rules.openBraceOnNewLineForAnonymousClasses - .editorconfig directive:
php_format_open_brace_on_new_line_for_anonymous_classes - .editorconfig alternative directive:
ij_php_anonymous_brace_style
| |
| true | false |
Open brace on a new line for blocks: Place open brace { on a new line for all types of code blocks, except for those controlled by other formatting rules.
- setting:
php.format.rules.openBraceOnNewLineForBlocks - .editorconfig directive:
php_format_open_brace_on_new_line_for_blocks - .editorconfig alternative directive:
ij_php_block_brace_style(values as in IntelliJ)
| |
| true | false |
Open brace on a new line for functions: Place open brace { on a new line for methods, functions and constructors.
- setting:
php.format.rules.openBraceOnNewLineForFunctions - .editorconfig directive:
php_format_open_brace_on_new_line_for_functions - .editorconfig alternative directive:
ij_php_method_brace_style(values as in IntelliJ)
| |
| true | false |
Open brace on a new line for lambda functions: Place open brace { on a new line for lambda functions.
- setting:
php.format.rules.openBraceOnNewLineForLambdas - .editorconfig directive:
php_format_open_brace_on_new_line_for_lambdas - .editorconfig alternative directive:
ij_php_lambda_brace_style(values as in IntelliJ)
| |
| true | false |
Open brace on a new line for namespaces: Place open brace { on a new line for namespace declarations.
- setting:
php.format.rules.openBraceOnNewLineForNamespaces - .editorconfig directive:
php_format_open_brace_on_new_line_for_namespaces - .editorconfig alternative directive:
ij_php_namespace_brace_style(values as in IntelliJ)
| |
| true | false |
Open brace on a new line for types: Place open brace { on a new line for types.
- setting:
php.format.rules.openBraceOnNewLineForTypes - .editorconfig directive:
php_format_open_brace_on_new_line_for_types - .editorconfig alternative directive:
ij_php_class_brace_style(values as in IntelliJ)
| |
| true | false |
Wrapping#
Align consecutive = assignments.: Automatically align consecutive = assignments.
- setting:
php.format.rules.alignConsecutiveAssignments - .editorconfig directive:
php_format_align_consecutive_assignments - .editorconfig alternative directive:
ij_php_align_assignments
| |
| true | false |
Align constants: Automatically align constant declarations
- setting:
php.format.rules.alignConstants - .editorconfig directive:
php_format_align_constants - .editorconfig alternative directive:
ij_php_align_class_constants
| |
| true | false |
Align enum cases: Automatically align assigned values in backed enumerations
- setting:
php.format.rules.alignEnumCases - .editorconfig directive:
php_format_align_enum_cases - .editorconfig alternative directive:
ij_php_align_enum_cases
| |
| true | false |
Align match arm bodies: Automatically align the bodies (results) within match expression arms
- setting:
php.format.rules.alignMatchArmBodies - .editorconfig directive:
php_format_align_match_arm_bodies - .editorconfig alternative directive:
ij_php_align_match_arm_bodies
| |
| true | false |
Align properties: Automatically align properties declarations
- setting:
php.format.rules.alignProperties - .editorconfig directive:
php_format_align_properties
| |
| true | false |
Align key-value pairs: Automatically align => operators.
- setting:
php.format.rules.arrayInitializersAlignKeyValuePairs - .editorconfig directive:
php_format_array_initializers_align_key_value_pairs - .editorconfig alternative directive:
ij_php_align_key_value_pairs
| |
| true | false |
New line after last element: Place a new line after the last element when wrapping.
- setting:
php.format.rules.arrayInitializersNewLineAfterLastElement - .editorconfig directive:
php_format_array_initializers_new_line_after_last_element - .editorconfig alternative directive:
ij_php_array_initializer_right_brace_on_new_line
| |
| true | false |
New line before first element: Place a new line before the first array element when wrapping.
- setting:
php.format.rules.arrayInitializersNewLineBeforeFirstElement - .editorconfig directive:
php_format_array_initializers_new_line_before_first_element - .editorconfig alternative directive:
ij_php_array_initializer_new_line_after_left_brace
| |
| true | false |
Wrap: _Defines wrapping behavior for array initializers. * Off - No wrapping is applied * On every item - When this option is selected each item is placed on a new line and properly indented if the array initializer is split across multiple lines. _
- setting:
php.format.rules.arrayInitializersWrap - .editorconfig directive:
php_format_array_initializers_wrap - .editorconfig alternative directive:
ij_php_array_initializer_wrap(values as in IntelliJ)
New line after (: Place a new line after the left opening parenthesis ( when wrapping.
- setting:
php.format.rules.callParametersNewLineAfterLeftParen - .editorconfig directive:
php_format_call_parameters_new_line_after_left_paren - .editorconfig alternative directive:
ij_php_call_parameters_new_line_after_left_paren
| |
| true | false |
New line before ): Place a new line before the right closing parenthesis ) when wrapping.
- setting:
php.format.rules.callParametersNewLineBeforeRightParen - .editorconfig directive:
php_format_call_parameters_new_line_before_right_paren - .editorconfig alternative directive:
ij_php_call_parameters_right_paren_on_new_line
| |
| true | false |
Wrap: _Defines wrapping behavior for method, function and constructor call parameters. * Off - No wrapping is applied * On every item - When this option is selected each item is placed on a new line and properly indented if the call arguments are split across multiple lines. _
- setting:
php.format.rules.callParametersWrap - .editorconfig directive:
php_format_call_parameters_wrap - .editorconfig alternative directive:
ij_php_call_parameters_wrap(values as in IntelliJ)
; on a new line: Place ; on a new line after the last element in the chained method call when wrapping.
- setting:
php.format.rules.chainedMethodCallsSemicolonOnNewLine - .editorconfig directive:
php_format_chained_method_calls_semicolon_on_new_line - .editorconfig alternative directive:
ij_php_multiline_chained_calls_semicolon_on_new_line
| |
| true | false |
Wrap: _Defines wrapping behavior for chained method calls. * Off - No wrapping is applied * Always - When this option is selected each method call is placed on a new line and properly indented. _
- setting:
php.format.rules.chainedMethodCallsWrap - .editorconfig directive:
php_format_chained_method_calls_wrap - .editorconfig alternative directive:
ij_php_method_call_chain_wrap(values as in IntelliJ)
Compact empty body into {}: Transform empty body into {} and keep it at the same line as a previous symbol, separated by single space.
- setting:
php.format.rules.declCompactEmptyBody - .editorconfig directive:
php_format_decl_compact_empty_body
| |
| true | false |
Keep ) and { on one line: Keep the right closing parenthesis ) of a function or method declaration header on the one line as opening brace of the body {.
- setting:
php.format.rules.declKeepRightParenAndOpenBraceOnOneLine - .editorconfig directive:
php_format_decl_keep_right_paren_and_open_brace_on_one_line - .editorconfig alternative directive:
ij_php_keep_rparen_and_lbrace_on_one_line
| |
| true | false |
New line after (: Place a new line after the left opening parenthesis ( of function or method declaration header when wrapping.
- setting:
php.format.rules.declParametersNewLineAfterLeftParen - .editorconfig directive:
php_format_decl_parameters_new_line_after_left_paren - .editorconfig alternative directive:
ij_php_method_parameters_new_line_after_left_paren
| |
| true | false |
New line before ): Place a new line before the right closing parenthesis ) of a function or method declaration header when wrapping.
- setting:
php.format.rules.declParametersNewLineBeforeRightParen - .editorconfig directive:
php_format_decl_parameters_new_line_before_right_paren - .editorconfig alternative directive:
ij_php_method_parameters_right_paren_on_new_line
| |
| true | false |
Wrap: _Defines wrapping behavior for method or function declaration parameters. * Off - No wrapping is applied * On every item - When this option is selected each declaration parameter is placed on a new line and properly indented if the arguments are split across multiple lines. _
- setting:
php.format.rules.declParametersWrap - .editorconfig directive:
php_format_decl_parameters_wrap - .editorconfig alternative directive:
ij_php_method_parameters_wrap(values as in IntelliJ)
New line after (: Place a new line after the left opening parenthesis ( in a for statement header if it's split across multiple lines.
- setting:
php.format.rules.forStatementNewLineAfterLeftParen - .editorconfig directive:
php_format_for_statement_new_line_after_left_paren - .editorconfig alternative directive:
ij_php_for_statement_new_line_after_left_paren
| |
| true | false |
New line before ): Place a new line after the right closing parenthesis ) in a for statement header if it's split across multiple lines.
- setting:
php.format.rules.forStatementNewLineBeforeRightParen - .editorconfig directive:
php_format_for_statement_new_line_before_right_paren - .editorconfig alternative directive:
ij_php_for_statement_right_paren_on_new_line
| |
| true | false |
Wrap: _Defines wrapping behavior for for statement. * Off - No wrapping is applied * On every item - When this option is selected each item in for statement is placed on a new line and properly indented if they are split across multiple lines. _
- setting:
php.format.rules.forStatementWrap - .editorconfig directive:
php_format_for_statement_wrap - .editorconfig alternative directive:
ij_php_for_statement_wrap(values as in IntelliJ)
New line before first group use declaration: Place a new line before first group use declaration if the list of declarations is split across multiple lines.
- setting:
php.format.rules.groupUseNewLineBeforeFirstDeclaration - .editorconfig directive:
php_format_group_use_new_line_before_first_declaration
| |
| true | false |
Wrap: _Defines wrapping behavior for group use list in type declarations. * Off - No wrapping is applied * On every item - When this option is selected each declaration in group use list is placed on a new line and properly indented if they are split across multiple lines. _
- setting:
php.format.rules.groupUseWrap - .editorconfig directive:
php_format_group_use_wrap - .editorconfig alternative directive:
ij_php_group_use_wrap(values as in IntelliJ)
New line after (: Place a new line after the left opening parenthesis ( in a if or elseif statement header if it's split across multiple lines.
- setting:
php.format.rules.ifStatementNewLineAfterLeftParen - .editorconfig directive:
php_format_if_statement_new_line_after_left_paren - .editorconfig alternative directive:
ij_php_if_lparen_on_next_line
| |
| true | false |
New line before ): Place a new line after the right closing parenthesis ) in a if or elseif statement header if it's split across multiple lines.
- setting:
php.format.rules.ifStatementNewLineBeforeRightParen - .editorconfig directive:
php_format_if_statement_new_line_before_right_paren - .editorconfig alternative directive:
ij_php_if_rparen_on_next_line
| |
| true | false |
Wrap: _Defines wrapping behavior for implements list in type declarations. * Off - No wrapping is applied * On every item - When this option is selected each interface in implements list is placed on a new line and properly indented if they are split across multiple lines. _
- setting:
php.format.rules.implementsListWrap - .editorconfig directive:
php_format_implements_list_wrap - .editorconfig alternative directive:
ij_php_extends_list_wrap(values as in IntelliJ)
Heredoc/Nowdoc Content Indentation: Ensures heredoc and nowdoc content lines are indented one level past the declaration's scope.
- setting:
php.format.rules.indentHeredoc - .editorconfig directive:
php_format_indent_heredoc
| |
| true | false |
Inline Heredoc/Nowdoc Declaration: Place heredoc and nowdoc on the same line as declaring variable
- setting:
php.format.rules.inlineHeredoc - .editorconfig directive:
php_format_inline_heredoc
| |
| true | false |
Keep classes on one line: Clasess are kept on one line.
- setting:
php.format.rules.keepClassesOnOneLine - .editorconfig directive:
php_format_keep_classes_on_one_line - .editorconfig alternative directive:
ij_php_keep_simple_classes_in_one_line
| |
| true | false |
Keep control statements on one line: Control statements are kept on one line.
- setting:
php.format.rules.keepControlStatementsOnOneLine - .editorconfig directive:
php_format_keep_control_statements_on_one_line - .editorconfig alternative directive:
ij_php_keep_control_statement_in_one_line
| |
| true | false |
Keep functions on one line: Functions and methods are kept on one line.
- setting:
php.format.rules.keepFunctionsOnOneLine - .editorconfig directive:
php_format_keep_functions_on_one_line - .editorconfig alternative directive:
ij_php_keep_simple_methods_in_one_line
| |
| true | false |
New line after implements: Place a new line after implements in type declaration if the list of interfaces is split across multiple lines.
- setting:
php.format.rules.newLineAfterImplements - .editorconfig directive:
php_format_new_line_after_implements
| |
| true | false |
New line after (: Place a new line after the left opening parenthesis ( in a switch statement header if it's split across multiple lines.
- setting:
php.format.rules.switchStatementNewLineAfterLeftParen - .editorconfig directive:
php_format_switch_statement_new_line_after_left_paren
| |
| true | false |
New line before ): Place a new line after the right closing parenthesis ) in a switch statement header if it's split across multiple lines.
- setting:
php.format.rules.switchStatementNewLineBeforeRightParen - .editorconfig directive:
php_format_switch_statement_new_line_before_right_paren
| |
| true | false |
New line after (: Place a new line after the left opening parenthesis ( in a while statement header if it's split across multiple lines.
- setting:
php.format.rules.whileStatementNewLineAfterLeftParen - .editorconfig directive:
php_format_while_statement_new_line_after_left_paren
| |
| true | false |
New line before ): Place a new line after the right closing parenthesis ) in a while statement header if it's split across multiple lines.
- setting:
php.format.rules.whileStatementNewLineBeforeRightParen - .editorconfig directive:
php_format_while_statement_new_line_before_right_paren
| |
| true | false |
Conversions#
Add a comma after the last array element: Automatically adds a comma after the last array element if it's not on a single line.
- setting:
php.format.rules.addCommaAfterLastArrayElement - .editorconfig directive:
php_format_add_comma_after_last_array_element - .editorconfig alternative directive:
ij_php_comma_after_last_array_element
Add a comma after the last function call parameters: Automatically adds a comma after the last function call parameter if it's not on a single line.
- setting:
php.format.rules.addCommaAfterLastCallParameter - .editorconfig directive:
php_format_add_comma_after_last_call_parameter - .editorconfig alternative directive:
ij_php_comma_after_last_argument
Add a comma after the last function declaration parameters: Automatically adds a comma after the last function or method declaration parameter if it's not on a single line.
- setting:
php.format.rules.addCommaAfterLastDeclParameter - .editorconfig directive:
php_format_add_comma_after_last_decl_parameter - .editorconfig alternative directive:
ij_php_comma_after_last_parameter
Boolean constant casing: _Defines casing for true and false constants. * uppercase - Changes the casing to upper case * lowercase - Changes the casing to lower case * keep - Keeps the original casing _
- setting:
php.format.rules.booleanConstantCasing - .editorconfig directive:
php_format_boolean_constant_casing - .editorconfig alternative directive:
ij_php_upper_case_boolean_const
| |
| lowercase | uppercase |
ImportSorting: Sort 'use' statements order. This setting affects how 'Organize imports' code action will sort 'use' statements.
- setting:
php.format.rules.importSorting - .editorconfig directive:
php_format_import_sorting - .editorconfig alternative directive:
ij_php_import_sorting(values as in IntelliJ)
ImportSortingCaseSensitive: Case-sensitive alphabetic sort of 'use' statements. Case sensitive sorting puts upper case letters on top.
- setting:
php.format.rules.importSortingCaseSensitive - .editorconfig directive:
php_format_import_sorting_case_sensitive
| |
| false | true |
Null constant casing: _Defines casing for null constant. * uppercase - Changes the casing to upper case * lowercase - Changes the casing to lower case * keep - Keeps the original casing _
- setting:
php.format.rules.nullConstantCasing - .editorconfig directive:
php_format_null_constant_casing - .editorconfig alternative directive:
ij_php_upper_case_null_const
| |
| lowercase | uppercase |
BlankLines#
Blank lines after class: Defines the number of blank lines after a class declaration.
- setting:
php.format.rules.blankLinesAfterClass - .editorconfig directive:
php_format_blank_lines_after_class - .editorconfig alternative directive:
ij_php_blank_lines_around_class
Blank lines after class body: Defines the number of blank lines after a class body.
- setting:
php.format.rules.blankLinesAfterClassBody - .editorconfig directive:
php_format_blank_lines_after_class_body - .editorconfig alternative directive:
ij_php_blank_lines_before_class_end
Blank lines after function: Defines the number of blank lines after a function declaration.
- setting:
php.format.rules.blankLinesAfterFunction - .editorconfig directive:
php_format_blank_lines_after_function - .editorconfig alternative directive:
ij_php_blank_lines_after_function
Blank lines after method: Defines the number of blank lines after a method declaration.
- setting:
php.format.rules.blankLinesAfterMethod - .editorconfig directive:
php_format_blank_lines_after_method - .editorconfig alternative directive:
ij_php_blank_lines_around_method
Blank lines after namespace: Defines the number of blank lines after a namespace declaration.
- setting:
php.format.rules.blankLinesAfterNamespace - .editorconfig directive:
php_format_blank_lines_after_namespace - .editorconfig alternative directive:
ij_php_blank_lines_after_package
Blank lines after open tag: Defines the number of blank lines after a open tag, except when the close tag is on the same line.
- setting:
php.format.rules.blankLinesAfterOpenTag - .editorconfig directive:
php_format_blank_lines_after_open_tag
Blank lines after use statements: Defines the number of blank lines after 'use' statements.
- setting:
php.format.rules.blankLinesAfterUseStatements - .editorconfig directive:
php_format_blank_lines_after_use_statements - .editorconfig alternative directive:
ij_php_blank_lines_after_imports
Blank lines around class constant: Defines the number of blank lines around a class constant.
- setting:
php.format.rules.blankLinesAroundClassConstant - .editorconfig directive:
php_format_blank_lines_around_class_constant
Blank lines around enum case: Defines the number of blank lines around an enum case.
- setting:
php.format.rules.blankLinesAroundEnumCase - .editorconfig directive:
php_format_blank_lines_around_enum_case
Blank lines around property: Defines the number of blank lines around a property.
- setting:
php.format.rules.blankLinesAroundProperty - .editorconfig directive:
php_format_blank_lines_around_property
Blank lines before class: Defines the number of blank lines before a class declaration.
- setting:
php.format.rules.blankLinesBeforeClass - .editorconfig directive:
php_format_blank_lines_before_class - .editorconfig alternative directive:
ij_php_blank_lines_around_class
Blank lines before class body: Defines the number of blank lines before a class body.
- setting:
php.format.rules.blankLinesBeforeClassBody - .editorconfig directive:
php_format_blank_lines_before_class_body - .editorconfig alternative directive:
ij_php_blank_lines_after_class_header
Blank lines before function: Defines the number of blank lines before a function declaration.
- setting:
php.format.rules.blankLinesBeforeFunction - .editorconfig directive:
php_format_blank_lines_before_function
Blank lines before function body: Defines the number of blank lines before a function body.
- setting:
php.format.rules.blankLinesBeforeFunctionBody - .editorconfig directive:
php_format_blank_lines_before_function_body
Blank lines before method: Defines the number of blank lines before a method declaration.
- setting:
php.format.rules.blankLinesBeforeMethod - .editorconfig directive:
php_format_blank_lines_before_method - .editorconfig alternative directive:
ij_php_blank_lines_around_method
Blank lines before method body: Defines the number of blank lines before a method body.
- setting:
php.format.rules.blankLinesBeforeMethodBody - .editorconfig directive:
php_format_blank_lines_before_method_body - .editorconfig alternative directive:
ij_php_blank_lines_before_method_body
Blank lines before namespace: Defines the number of blank lines before a namespace declaration.
- setting:
php.format.rules.blankLinesBeforeNamespace - .editorconfig directive:
php_format_blank_lines_before_namespace - .editorconfig alternative directive:
ij_php_blank_lines_before_package
Blank lines before return statement: Defines the number of blank lines before a return statement.
- setting:
php.format.rules.blankLinesBeforeReturnStatement - .editorconfig directive:
php_format_blank_lines_before_return_statement
Blank lines before use statements: Defines the number of blank lines before 'use' statements.
- setting:
php.format.rules.blankLinesBeforeUseStatements - .editorconfig directive:
php_format_blank_lines_before_use_statements - .editorconfig alternative directive:
ij_php_blank_lines_before_imports
Blank lines between different use types: Defines the number of blank lines between different types of use statements (e.g., classes, functions, constants), but not between the same type.
- setting:
php.format.rules.blankLinesBetweenUseTypes - .editorconfig directive:
php_format_blank_lines_between_use_types
Maximum blank lines in code: Defines the maximum number of consecutive blank lines allowed in the code.
- setting:
php.format.rules.maxBlankLines - .editorconfig directive:
php_format_max_blank_lines - .editorconfig alternative directive:
ij_php_keep_blank_lines_in_code