🐛 fix initial load

This commit is contained in:
2026-06-08 20:11:24 +10:00
parent 9351916de3
commit 9a39fe6cb5

View File

@@ -92,10 +92,12 @@ export function MarkdownEditor(): JSX.Element {
useEffect(() => {
if (!editorRef.current) return
const isDark = theme === 'dark'
const { activeStoryContent, activeStoryPath } = useBorgesStore.getState()
lastPathRef.current = activeStoryPath
const view = new EditorView({
state: EditorState.create({
doc: '',
doc: activeStoryContent,
extensions: [
history(),
markdown(),