aboutsummaryrefslogtreecommitdiffhomepage
path: root/src
diff options
context:
space:
mode:
authorHsieh Chin Fan <pham@topo.tw>2024-09-11 19:11:20 +0800
committerHsieh Chin Fan <pham@topo.tw>2024-09-11 19:11:27 +0800
commit449f2aacc7a89df06465e9b30c4df9eb39c19205 (patch)
tree05bb613d902fcf79746650457589ddaf67c5a3a1 /src
parent0e6110ad9be2e444880b13e9f670f636ccd09381 (diff)
style: reformat code
Diffstat (limited to 'src')
-rw-r--r--src/editor.mjs8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/editor.mjs b/src/editor.mjs
index 107743b..783e654 100644
--- a/src/editor.mjs
+++ b/src/editor.mjs
@@ -82,9 +82,9 @@ cm.on("change", () => {
82// }}} 82// }}}
83 83
84// Reload editor content by hash value 84// Reload editor content by hash value
85onhashchange = () => { 85window.onhashchange = () => {
86 const contentFromHash = getContentFromHash() 86 const content = getContentFromHash(window.location.hash)
87 if (contentFromHash) editor.value(contentFromHash) 87 if (content) editor.value(content)
88} 88}
89 89
90// FIXME DEBUGONLY 90// FIXME DEBUGONLY
@@ -259,7 +259,7 @@ const getSuggestions = (anchor) => {
259 }) 259 })
260 .catch(() => { 260 .catch(() => {
261 markInputIsInvalid(lineWithRenderer) 261 markInputIsInvalid(lineWithRenderer)
262 console.warn(`Fail to get valid options from renderer with URL ${rendererUrl}` ) 262 console.warn(`Fail to get valid options from renderer with URL ${rendererUrl}`)
263 }) 263 })
264 return [] 264 return []
265 } 265 }