Hacktoberfest 2026 : les issues que les mainteneurs ont marquées pour octobre, ouvertes et accessibles aux débutants. Parcourir les issues Hacktoberfest

CollaborationExtension registered at runtime installs no sync plugin, so edits never reach the Y.Doc

Ouverte
#3,175 0 commentaires 0 réactions 0 personnes assignées Voir sur GitHub

Les mainteneurs répondent en général sous 2 jours

@adarshsm y travaille déjà.

Depuis le 10/10/2026.

  • #3178 par @adarshsm — ouverte

Évaluation

Difficulté
4/5
Temps estimé
3-5 jours
Accessibilité débutants
25/100
Type d'issue
Bug
Clarté
Plutôt claire
Activité
Active
Stack technique
react, typescript
Domaine
frontend, web-dev

Piste de recherche

Start in ExtensionManager.replaceExtension, which installs the plugins of the extension passed in but skips its nested blockNoteExtensions; CollaborationExtension is where YSync, YCursor and YUndo live. Reproduce by creating an editor without the collaboration option and registering CollaborationExtension at runtime, then check whether the Y.XmlFragment changes after typing. Done means nested extensions are installed on runtime registration, or registration throws when they cannot be.

Rédigé par le modèle d'indexation à partir du texte de l'issue.

Description

Version: BlockNote 0.55 (@blocknote/core, @blocknote/react)

What happens

Collaboration registered on an editor that already exists doesn't sync. The editor becomes editable, typing works locally, and nothing is written to the Y.XmlFragment, so edits are silently lost.

We create a read-only editor without collaboration (fed a static snapshot, no provider). When the user switches to editing, we attach collaboration to that same editor instead of remounting it, which keeps scroll position and node views stable.

Cause (from reading the source)

ExtensionManager.replaceExtension installs the ProseMirror plugins of the extension it is given, but not those of that extension's nested blockNoteExtensions. For CollaborationExtension, the nested ones carry the actual plugins: YSync, YCursor, YUndo and the rest. So none of them are installed.

Workaround

Registering the sub-extensions flat works, in this order (the cursor plugin reads the sync plugin's state in its init):

  • YSync
  • YCursor
  • YUndo
  • ForkYDoc
  • RelativePositionMapping
  • SchemaMigration

FixUpSchemaExtension is not exported, so it can't be registered that way.

Repro
  1. Create an editor without the collaboration option.
  2. Register CollaborationExtension at runtime, with a Y.XmlFragment and a provider.
  3. Type in the editor.
  4. The fragment stays empty, and other clients see nothing.
Expected

Either nested blockNoteExtensions are installed when an extension is registered at runtime, or registering an extension whose nested extensions can't be installed throws instead of failing silently. A documented way to attach collaboration to an existing editor would also help.

Langage dominant
TypeScript
Étoiles
10.3k
Forks
778
Merge moyen
2 j 12 h
PR mergées (30 j)
27

Préparer son environnement

Par où commencer

  1. Lisez l'issue en entier, puis le guide de contribution du projet.
  2. Signalez en commentaire que vous la prenez — cela évite que deux personnes fassent le même travail.
  3. Forkez le dépôt et travaillez sur une branche.
  4. Ouvrez une pull request qui référence le numéro de l'issue.

Autres issues de TypeCellOS/BlockNote

Toutes les issues de TypeCellOS/BlockNote

Issues similaires

Plus d'issues TypeScript

Recevez les nouvelles issues par e-mail

Un résumé court des issues GitHub adaptées aux débutants.