Add new logOnce() method and fix for error messages

This commit is contained in:
2023-12-25 13:09:36 +02:00
parent 2d933ae223
commit fea2a3eb21
4 changed files with 13 additions and 2 deletions

View File

@ -106,6 +106,7 @@ export const registerOnKeyDown = (app: Editor) => {
event.preventDefault();
app.currentFile().candidate = app.view.state.doc.toString();
app.api.onceEvaluator = true;
app.api.forceEvaluator = true;
tryEvaluate(app, app.currentFile());
app.flashBackground("#404040", 200);
}
@ -115,7 +116,7 @@ export const registerOnKeyDown = (app: Editor) => {
event.preventDefault();
app.api.clearPatternCache();
app.currentFile().candidate = app.view.state.doc.toString();
app.api.onceEvaluator = true;
app.api.forceEvaluator = true;
tryEvaluate(app, app.currentFile());
app.flashBackground("#404040", 200);
}