IntelliJ Platform Plugin SDK
 
IntelliJ Platform Explorer

Code Formatter

Edit pageLast modified: 18 November 2024

The IntelliJ Platform includes a powerful framework for implementing custom language formatters. At its core, the framework represents formatting rules by nested blocks (Block) that cover the whole file. Each block specifies constraints on whitespaces, like indents, wraps, spacing, or alignments. This allows the formatting engine to calculate the smallest number of whitespace modifications necessary to properly format a file.