react-codemirror icon indicating copy to clipboard operation
react-codemirror copied to clipboard

omit the confusing `defaultValue` type from props

Open tiny-ant opened this issue 5 months ago • 1 comments

I'm trying to solve a bug caused by the controlled value props from parent (in some case the cursor jumps to the start of line, in some other cases it rolls back part of the input), since value and defaultValue are both defined in props, so I tried to use defaultValue to get rid of controlling the value state, then... oh shit , this is a trap ! it's worse than a bug !

tiny-ant avatar Jul 28 '25 09:07 tiny-ant