| id | dxHtmlEditor.Options.customizeModules |
|---|---|
| type | function(config) |
Allows you to customize the DevExtreme Quill and 3rd-party modules.
Module configurations.
The DevExtreme Quill modules and the API you can use to customize them are described in the Modules documentation section. For example, the History module, which handles the undo and redo operations, can be customized as follows:
<!-- tab: index.js -->
$("#html-editor").dxHtmlEditor({
customizeModules(config) {
config.history = {
delay: 0,
maxStack: 5000
};
}
});
<!-- tab: app.component.html -->
<dx-html-editor
[customizeModules]="customizeQuillModules">
</dx-html-editor>
<!-- tab: app.component.ts -->
import { Component } from '@angular/core';
import { DxHtmlEditorModule } from 'devextreme-angular/ui/html-editor';
// ...
export class AppComponent {
customizeQuillModules(config) {
config.history = {
delay: 0,
maxStack: 5000,
};
}
}
<!-- tab: App.vue -->
<template>
<DxHtmlEditor
:customize-modules="customizeQuillModules"
/>
</template>
<script>
import { DxHtmlEditor } from 'devextreme-vue/html-editor';
function customizeQuillModules(config) {
config.history = {
delay: 0,
maxStack: 5000,
};
}
</script>
<!-- tab: App.tsx -->
import React from 'react';
import { HtmlEditor } from 'devextreme-react/html-editor';
export default function App() {
const customizeQuillModules = useCallback((config) => {
config.history = {
delay: 0,
maxStack: 5000,
};
}, []);
return (
<HtmlEditor
customizeModules={customizeQuillModules}
/>
);
}
You can configure customizeModules to modify the keyboard navigation behavior of HtmlEditor using keyboard.inlineTabInsertion:
<!-- tab: index.js -->
$("#html-editor").dxHtmlEditor({
customizeModules(config) {
config.keyboard.inlineTabInsertion = false;
}
});
<!-- tab: app.component.html -->
<dx-html-editor
[customizeModules]="customizeQuillModules">
</dx-html-editor>
<!-- tab: app.component.ts -->
import { Component } from '@angular/core';
import { DxHtmlEditorModule } from 'devextreme-angular/ui/html-editor';
// ...
export class AppComponent {
customizeQuillModules(config) {
config.keyboard.inlineTabInsertion = false;
}
}
<!-- tab: App.vue -->
<template>
<DxHtmlEditor
:customize-modules="customizeQuillModules"
/>
</template>
<script>
import { DxHtmlEditor } from 'devextreme-vue/html-editor';
function customizeQuillModules(config) {
config.keyboard.inlineTabInsertion = false;
}
</script>
<!-- tab: App.tsx -->
import React from 'react';
import { HtmlEditor } from 'devextreme-react/html-editor';
export default function App() {
const customizeQuillModules = useCallback((config) => {
config.keyboard.inlineTabInsertion = false;
}, []);
return (
<HtmlEditor
customizeModules={customizeQuillModules}
/>
);
}
If 3rd-party modules are used in the HTML Editor, refer to their documentation for information on the API.
#####See Also#####