merge feat/212-editor-git-gutter into dev(#212 编辑器变更提示:code 视图行号槽着色 + 左侧细色条 + hover blame,一个布尔开关,样式极简)
This commit is contained in:
commit
bce22cfaf1
37 files changed
+1376
-5
No files matched your search
@@ -322,7 +322,10 @@ export function useGitStatus(
|
||||
slot.listeners.add(listener)
|
||||
return () => { slot.listeners.delete(listener) }
|
||||
}, [slot])
|
||||
useSyncExternalStore(subscribe, () => slot.version)
|
||||
// The third argument (server snapshot) keeps a consumer that is rendered to
|
||||
// a string alive — the editor does exactly that in the markdown specs, and
|
||||
// the slot's version is 0 on both sides.
|
||||
useSyncExternalStore(subscribe, () => slot.version, () => slot.version)
|
||||
|
||||
useEffect(() => {
|
||||
slot.pollMs = pollMs
|
||||
|
||||
Reference in new issue
Block a user