Skip to content

Commit 4e920ef

Browse files
committed
fix(#131): wrong history for speculative updates
1 parent aa6bc28 commit 4e920ef

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

packages/carta-md/src/lib/internal/components/Input.svelte

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -140,6 +140,8 @@
140140
debouncedHighlight(value);
141141
142142
highlightNestedLanguages(value);
143+
144+
prevValue = value;
143145
};
144146
145147
$: if (BROWSER) onValueChange(value);
@@ -195,7 +197,6 @@
195197
bind:value
196198
bind:this={textarea}
197199
on:scroll={() => (textarea.scrollTop = 0)}
198-
on:keydown={() => (prevValue = value)}
199200
></textarea>
200201
</div>
201202

0 commit comments

Comments
 (0)