Formatting on demand
Formatting is a separate enhancement. Opening Source should not fetch Prettier; invoking the formatting command loads the required tools.
Formatting can change whitespace and serialization without removing meaningful CMS HTML. Inspect the result and use undo when needed. Automatic formatting requires explicit source.autoFormat configuration and is off by default.
Checked code
ts
export async function format(editor: ClassicEditor) {
await editor.setWorkspaceView('source');
await editor.editor.execute('document.format');
}Checked against the published types; see imports and types for imports.