this is the markText api with a ‘atomic’ option
in codemirror 6 the Decoration.mark not support pass a element, so I use Decoration.replace pass a widget
but how do I implement ‘atomic’ effect with Decoration.replace,I don’t find any option seem to implement this effect
marijn
August 10, 2022, 12:06pm
2
Set up EditorView.atomicRanges
to get the same decoration set you’re using for the replacements.
hello,
your function of mention isn’t simple ,
could show me a demo
marijn
August 29, 2022, 1:49pm
4
I’ve added an example to the decoration example that uses atomicRanges
.
I apologize now I see your reply.
I need to set up in the range. not Regexp ,
and the best way that can turn off the state