Fork me on GitHub
#reagent
<
2018-11-26
>
João Lucas18:11:13

Hello guys. I'm trying to use Draft.js, however sometimes the cursor jumps to the beginning of the line. Has anyone managed to make it work properly? Is there a WYSIWYG component that works "out of the box" with reagent?

mikerod18:11:07

@jlucas.nsilva that’s a common issue

mikerod18:11:44

this was addressing the same sort of issue when using MUI component for text input

mikerod18:11:55

but it can be twisted to other components with the problem from what I’ve seen

João Lucas18:11:25

Thank you, @mikerod. I've being working with Material UI, my problem with Draft.js is that

João Lucas18:11:04

I couldn't find a way to make reagent draw the root component (which is not a 'input' element).

mikerod19:11:37

@jlucas.nsilva you may need to do a form-3 style component, but not sure what you have setup

mikerod19:11:38

but still, I don’t think I’d know enough of what you have to help without an example I think

mikerod19:11:02

I’ve worked with ace editor in reagent before by using a form-3 component. I don’t believe the cursor jumping was an issue, but I think it was uncontrolled at the text level

João Lucas19:11:05

I see. I'll try it. Thank you very much, @mikerod.