Save work periodically to reduce loss from crashes (#1580)

* Add auto saving

* Fix autosave dispatching message but not saving document

* Clamp set_timeout delay

* Auto save all documents instead of only the active

* Add with_editor to simplify code

* Update consts

* Simplify some more

* Fix typo

* Code review

---------

Co-authored-by: Keavon Chambers <keavon@keavon.com>
This commit is contained in:
Comeza
2024-02-20 03:23:25 +00:00
committed by GitHub
co-authored by Keavon Chambers
parent f265fa693e
commit dc7de4d973
5 changed files with 110 additions and 46 deletions
+1
View File
@@ -41,6 +41,7 @@ features = [
"CanvasRenderingContext2d",
"Document",
"HtmlCanvasElement",
"IdleRequestOptions"
]
[package.metadata.wasm-pack.profile.dev]