codex-team / codex-team/editor.js
[bug] onChange is thrown infinitely with image-simple and mermaid plugins
- Langage dominant
- TypeScript
- Étoiles
- 31.9k
- Forks
- 2.2k
- Merge moyen
- 1 j 1 h
- PR mergées (30 j)
- 1
Description
I'm working on a editorjs app synced by Yjs.
it seems to work great with most of the plugins. and sync is reported to other users, but with two plugins (image-simple & mermaid), the onChange function seems to be thrown every second .
I use the onChange function to save the editor content to a yMap of Yjs
The issue is that each of the two users, get infinite refresh of the page.
is this onChange event thrown by the editor or by the concerned plugins ? is this an issue for each plugin ?
my editor code is here https://github.com/scenaristeur/noosphere/blob/main/src/views/EditorView.vue
see demo video and working app at https://scenaristeur.github.io/noosphere/about
https://user-images.githubusercontent.com/4020744/189363842-d732cdf5-f988-46bc-9919-2d83e89ebaa2.mp4
Guide de contribution
Aucun guide de contribution indexé pour ce dépôt
Piste de recherche
Commencez par le fichier src/views/EditorView.vue lié et reproduisez le comportement en utilisant les plugins image-simple et mermaid, avec le gestionnaire onChange et la synchronisation Yjs décrits dans l’issue. Comparez, en vous servant de la démo et de la vidéo liées comme références comportementales, si les événements onChange répétés proviennent de l’éditeur ou de l’un des plugins. Le travail est terminé lorsque la source a été identifiée et que le cycle de rafraîchissement infini a été arrêté.
Rédigé par le modèle d'indexation à partir du texte de l'issue.
Évaluation
- Stack technique
- javascript, typescript
- Domaine
- frontend
- Type d'issue
- Bug
- Difficulté
- 4/5
- Temps estimé
- 3-5 jours
- Activité
- À l'abandon
- Clarté
- À clarifier
- Accessibilité débutants
- 25/100