Replies: 2 comments 2 replies
|
I was using a React const textEditorDoenetML = useRef(initial_doenetml_from_database);
<DoenetEditor
doenetML={textEditorDoenetML.current}
immediateDoenetmlChangeCallback={(newDoenetML: string) => {
textEditorDoenetML.current = newDoenetML;
}}
/>The sequence I was running into was:
|
2 replies
|
Fixing this alone would have been a bit beyond me. (I gave up on previous tries.) This time, working with Claude, we now have PR #1131. i hope it will fix the issue. |
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
I'm trying to wrap my head around how the
doenetMLprop in<DoenetEditor>is supposed to be used. Is it supposed to be a controlled prop that the editor updates every time users type something? Or is it supposed to represent the initial doenetml when the page loads?Context: I'm running into a bug where React triggers a new render on my page and that is causing the editor to reload. Not sure if the issue is caused by incorrect usage of
doenetMLprop on my part or by something in@doenet/doenetml-iframe.All reactions