@setoelkahfi / svara / commits / ed6b457

some cleanup

mellobacon committed Aug 25, 2022 at 13:37 UTC ed6b45798238c6b78e87aa5911e01bedc8a8f4dd
1 file changed +3 -3
src/components/Content/Editor/Tabs.ts
+3 -3
@@ -22,10 +22,10 @@ class Tab {
22 this.editorcontent = editorcontent
23 this.saved = saved;
24
25 - let x = undefined;
25 + let _ = undefined;
26 this.editor.$on("input", (e) => {
27 - clearTimeout(x);
28 - x = setTimeout(() => {
27 + clearTimeout(_);
28 + _ = setTimeout(() => {
29 writeFile(this.path, e.detail);
30 console.log(`${this.label} saved`)
31 }, 1000)