M
M
Mikhail Teslya2021-04-21 00:17:58
CKFinder
Mikhail Teslya, 2021-04-21 00:17:58

How to integrate CKFinder with CKEditor 5 vue?

Tell me how it is right, who did it? If I separately do the import, it says that the module is duplicated, it turns out to make it work only by connecting to the page body, but this is not an option here, because. I need it only in a certain component, otherwise the error "Cannot read property 'modal' of undefined" takes off! What does he need, how to achieve the right integration?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
M
Mikhail Teslya, 2021-04-21
@Sangfroid

At the moment I came up with this implementation:

mounted() {
        if (!document.querySelector('#ckfinder-script')) {
            const script = document.createElement('script');
            script.id = 'ckfinder-script';
            script.async = true;
            script.src = '/ckfinder/ckfinder.js';
            document.body.append(script);
        }
    }

I think it will be useful for people with a similar problem, if there is a normal way, I will add

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question