Hi, I want to insert text into the onlyoffice editor in my VUE3 project

How can I insert text into the onlyoffice editor in my VUE3 project with onlyoffice community. Does OnlyOffice Community Edition support external calls to the OnlyOffice editor via the API? how do i implement it?

I use newest docker image

Hello,
It can be done only by writing a plugin. The code is as follows:

window.Asc.plugin.callCommand(function () {
    var oDocument = Api.GetDocument();
    var oParagraph = Api.CreateParagraph();
    oParagraph.AddText("Hello world!");
    oDocument.InsertContent([oParagraph]);
}, true);
1 Like

hi , thanks for your reply ! how can I use this in my vue code,

hi there is not plugin in vue3 ,PLZ help me

If you want to use plugin methods directly from your Vue app, instead of from the plugin itself, then you need to purchase the Automation API - Automation API | ONLYOFFICE