Skip to content

ckeditor-duplicated-modules error #4

Description

@alokjain-lucky
"dependencies": {
        "@ckeditor/ckeditor5-build-classic": "^36.0.1",
        "@ckeditor/ckeditor5-react": "^5.0.2",
}

React Component for Editor

import { CKEditor } from "@ckeditor/ckeditor5-react";
import ClassicEditor from "@ckeditor/ckeditor5-build-classic";

import ResizableHeight from "@pikulinpw/ckeditor5-resizableheight";

// override the default styles
import "./custom.css";

const Editor = ({ data, setData, config = {}, height = "200px" }) => {
    return (
        <CKEditor
            editor={ClassicEditor}
            config={{
                toolbar: {
                    shouldNotGroupWhenFull: true,
                },
                plugins: [ResizableHeight],
                ...config,
            }}
            data={data}
            onChange={(event, editor) => {
                const data = editor.getData();
                setData(data);
            }}
            onReady={(editor) => {
                editor.editing.view.change((writer) => {
                    writer.setStyle(
                        "height",
                        height,
                        editor.editing.view.document.getRoot(),
                    );
                });
            }}
        />
    );
};

export default Editor;

It says: ckeditor-duplicated-modules Read more: https://ckeditor.com/docs/ckeditor5/latest/support/error-codes.html#error-ckeditor-duplicated-modules

Please suggest how do I fix this error?

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions