tabWidth (default: 4): Number of spaces per indentation level
useTabs (default: false): Use tabs instead of spaces for indentation
printWidth (default: 120): Specify the line length that the printer will wrap on
removeEmptyElements (default false): Remove elements without content (this includes table fieldgroups, page actions and layout sections)
Requirements
VS Code 1.75 or later
AL language support (from Microsoft Dynamics 365 Business Central AL Language extension)
Known issues and limitations
Requires valid AL syntax to format correctly. Formatting of an AL statement that cannot be parsed correctly will throw an error.
Range formatting is in development and currently not supported.
#pragma, #if not CLEANX and similar precompiler instructions are interpreted as leading comments for the next token and may be unaligned after formatting.
Not all AL objects are supported (yet). Currently supported objects:
Codeunit
Enum
Enum extension
Interface
Page
Page extension
Query
Report (without embedded RDL layout)
Table
Table extension
Contributing
Contributions are welcome! Please submit issues and pull requests to the repository.