Configure code folding detection
mainBy default, Re-Editor automatically detects folding regions for {} and [].
- To use the default detector: Use
DefaultCodeChunkAnalyzer(). - To disable detection: Use
NonCodeChunkAnalyzer(). - To implement custom logic: Implement the
CodeChunkAnalyzerinterface.
// Using default analyzer
CodeEditor(
chunkAnalyzer: DefaultCodeChunkAnalyzer(),
);
// Custom implementation interface
abstract class CodeChunkAnalyzer {
List<CodeChunk> run(CodeLines codeLines);
}