To add custom Quill modules, use the customModules array within your QuillConfig. Each entry must be a CustomModule object containing a path and an implementation.
The implementation can be the module constructor itself or an Observable that resolves to the constructor, allowing for lazy loading.
Example: Synchronous implementation
customModules = [
{ path: 'modules/blotFormatter', implementation: BlotFormatter }
];
Example: Lazy-loaded implementation
import { defer, from } from 'rxjs';
const BlotFormatter$ = defer(() => import('quill-blot-formatter').then(m => m.default));
customModules = [
{ path: 'modules/blotFormatter', implementation: BlotFormatter$ }
];
export interface CustomModule {
implementation: any
path: string
}