Jungwoo-An / react-editor-js

⚛️📝The unofficial editor-js component for React
https://codesandbox.io/s/react-editor-js-v2-34bfl
MIT License
940 stars 77 forks source link

Can't Input Text #206

Closed fiik346 closed 3 months ago

fiik346 commented 2 years ago

Environment

Describe

I can't Input anything, but no warning or error in console. This is my code

// pages/newpost.js
import dynamic from 'next/dynamic'
const CustomEditor = dynamic(()=>import('../components/editor'),{ssr:false})
export default function NewPost(){
  return (
    <> <CustomEditor /></>
  )
}

Components code

// components/editor.js
import { createReactEditorJS } from 'react-editor-js'                                   
const Header = require('@editorjs/header')
export default function CustomEditor({data}){

  const ReactEditorJS = createReactEditorJS()

  const TOOLS = {
    header: Header,
  }
 return(
    <ReactEditorJS tools={TOOLS} holder="editor">                                 
<div id="editor" className="my-4 border h-64 relative"></div>
    </ReactEditorJS>
  )
}

In console that is ready to use but, I try tap the editorjs and not do anything IMG_20220721_115353

fiik346 commented 2 years ago

IMG_20220721_130033

after look element is like EditorJS not rendered

Maxfri commented 2 years ago

Perhaps you should disable in your index.jsx

msnisha commented 1 year ago

@Maxfri Thanks it helped me to solve rending issue. Is it a bug needs to be addressed in the component to support strict mode?