Using ES6 modules
Подскажите, не пойму,
как понимать вот эту инструкцию? import Vue from 'vue'; import CKEditor from '@ckeditor/ckeditor5-vue'; Vue.use( CKEditor ); Instead of calling Vue.use(), you can always use the component locally.
<template>
<div id="app">
<ckeditor :editor="editor" ... ></ckeditor>
</div>
</template>
<script>
export default {
name: 'app',
components: {
// Use the <ckeditor> component in this view.
ckeditor: CKEditor.component
},
data() {
return {
editor: ClassicEditor,
// ...
};
}
}
</script>
https://ckeditor.com/docs/ckeditor5/...ponent-locally никак не могу добится что бы работало локально делаю импорт import CKEditor from '@ckeditor/ckeditor5-vue'; дальше согласно доке объявляю компонент
components: {
// Use the <ckeditor> component in this view.
ckeditor: CKEditor.component
},
естественно он не находит модуль .... |
Раз не находит значит его наверное нет?)
npm i @ckeditor/ckeditor5-vue или yarn add @ckeditor/ckeditor5-vue |
разобрался, чота тупил тупил, потом разобрался
import CKEditor from '@ckeditor/ckeditor5-vue';
import ClassicEditor from '@ckeditor/ckeditor5-build-classic';
//
components: {
ckeditor: CKEditor.component,
},
|
| Часовой пояс GMT +3, время: 07:29. |