Skip to content

Commit 4eaff43

Browse files
committed
Fix build and snapshot runner dependency conflicts
1 parent 9c442a4 commit 4eaff43

3 files changed

Lines changed: 12 additions & 16 deletions

File tree

examples/07-collaboration/12-multi-doc-versioning/src/sampleDocument.ts

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -141,9 +141,11 @@ export async function seedSampleDocument(options: {
141141
.prosemirrorState.doc;
142142
const at = Math.floor(Date.now() - version.daysAgo * DAY_MS);
143143
ydoc.transact(() => {
144-
fragment.applyDelta(
145-
(previous ? docDiffToDelta(previous, pmDoc) : docToDelta(pmDoc)) as any,
146-
);
144+
if (previous) {
145+
fragment.applyDelta(docDiffToDelta(previous, pmDoc));
146+
} else {
147+
fragment.applyDelta(docToDelta(pmDoc));
148+
}
147149
if (version.name !== undefined) {
148150
versions.push([{ id: at, name: version.name }] as never);
149151
}

pnpm-lock.yaml

Lines changed: 6 additions & 12 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

pnpm-workspace.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ overrides:
3636
# `toMatchSnapshot` fails with "The snapshot state for '...' is not found".
3737
# Pin both so the whole workspace shares one instance.
3838
"@types/node": "25.9.5"
39-
"jsdom": "^29.0.2"
39+
"jsdom": "29.0.2"
4040
"vitest": "4.1.10"
4141
"@vitest/runner": "4.1.10"
4242
# @vitest/mocker must stay >=4.1.10: earlier builds only recognize `vitest`

0 commit comments

Comments
 (0)