Modify the source code vue-html5-editor.js
Directory:
open this file, search for contenteditable, add id = “container”
and then search for Keyup
comment code
// content.addEventListener('keyup', function () {
// this$1.$emit('change', content.innerHTML);
// this$1.saveCurrentRange();
// }, false);
Add code
const handleListenChange = (mutationsList, observer) => {
this$1.$emit('change', content.innerHTML);
this$1.saveCurrentRange();
}
const mutationObserver = new MutationObserver(handleListenChange)
const element = document.querySelector('#container')
const options = {
attributes: true,
childList: true,
subtree: true,
characterData: true
}
It’s like this on the whole
I’ve looked at others and modified it myself. This question is more detailed than that of the blogger. Link to attach. If you have any other questions, take a look
CSDN of Dashen
Read More:
- An error is reported when installing the package directly in pycharm, but it can be installed through the terminal. Error non zero exit code (2)
- JS Mobile Page to determine whether it is iPhone X, and then set the corresponding height of the element?
- The Vue mobile terminal cannot use string.replaceall, and the error message is blank
- “ XX.app ”It is damaged and cannot be opened. You should move it to the wastebasket.
- When a system is deployed on weblogic12.2.1.3, it reports an error “IllegalStateException zip file closed”. When it is deployed on weblogic12.2.1.2, it does not report an error and can be accessed normally.
- Add a new springboot, and it will appear unable to read meta data for class when it is dependent
- [Error] because it violates the following Content Security Policy directive
- It will appear as soon as it is turned on BTServer.exe -Application error (0xc0150002)
- The Vue project is packaged and deployed to tomcat, and an Error 404 is reported as soon as it is refreshed
- The software of Final Cut Pro x 10.5 failed to open, and it flashed back directly.
- The problem of error in adaptation of Vue using vant mobile terminal rem
- After canceling the startup of Ubuntu terminal, it will automatically enter the base environment of CONDA
- Vue3 uses element plus package to solve the problem of occasionally disordered code on the icon after it goes online
- You set the variable “no_check_targets“ here and it was unused before it went out of scope.
- After JQ gets the tag element itself, it gets its own HTML text format (find only finds one level of child elements)
- Vue introduction path is correct, but it always reports an error: already included file name‘ ××ב differs from file name ‘ ××ב only in casing.
- Writing to settings when appium of Xiaomi mobile phone and oppo mobile phone starts requires:android.permission.WRITE_ SECURE_ SETTINGS
- Inline JavaScript is not enabled. Is it set in your options?
- MISCONF Redis is configured to save RDB snapshots, but it is currently not able to persist on disk.
- When SSM + Maven project is running, it is prompted that org.springframework.web.servlet.dispatcherserservlet cannot be found