소스 검색

comment on setTimeout in undo

Tienson Qin 2 년 전
부모
커밋
047653bd97
1개의 변경된 파일1개의 추가작업 그리고 0개의 파일을 삭제
  1. 1 0
      src/main/frontend/handler/history.cljs

+ 1 - 0
src/main/frontend/handler/history.cljs

@@ -46,6 +46,7 @@
   (let [{:keys [editor-cursor app-state]} (undo-redo/undo)]
     (restore-cursor! editor-cursor)
     (restore-app-state! app-state))
+  ;; ugly timeout: avoid save block from frontend.handler.editor.lifecycle/will-unmount
   (js/setTimeout #(state/set-editor-op! nil) 100))
 
 (defn redo!