refactor(editor): playground doc collection typing migration (#9593)

This commit is contained in:
doodlewind
2025-01-09 03:07:43 +00:00
parent 5ff2254c83
commit e269cce141
19 changed files with 48 additions and 84 deletions

View File

@@ -1,12 +1,9 @@
import type { DocCollection } from '@blocksuite/store';
import type { Workspace } from '@blocksuite/store';
import * as Y from 'yjs';
import type { InitFn } from './utils.js';
export const versionMismatch: InitFn = (
collection: DocCollection,
id: string
) => {
export const versionMismatch: InitFn = (collection: Workspace, id: string) => {
const doc = collection.createDoc({ id });
const tempDoc = collection.createDoc({ id: 'tempDoc' });
doc.load();