Ueditor禁用Enter换行

Ueditor禁用Enter换行

editor.addListener("keydown", function (type, event) {
     if (event.which == 13) {  //  13 Enter
        // 禁止换行
        event.cancelBubble = true;
        event.preventDefault();
        event.stopPropagation();

       }
     });
发布了23 篇原创文章 · 获赞 14 · 访问量 1万+

猜你喜欢

转载自blog.csdn.net/qq_35001005/article/details/79144142