steven-tey / novel

Notion-style WYSIWYG editor with AI-powered autocompletion.
https://novel.sh
Apache License 2.0
12.47k stars 1.03k forks source link

bug: Using two editors in the same repository creates problems #439

Open bakikucukcakiroglu opened 3 weeks ago

bakikucukcakiroglu commented 3 weeks ago

Provide environment information

System: OS: macOS 14.5 CPU: (11) arm64 Apple M3 Pro Memory: 84.16 MB / 18.00 GB Shell: 5.9 - /bin/zsh Binaries: Node: 20.15.1 - ~/.nvm/versions/node/v20.15.1/bin/node Yarn: 1.22.22 - /opt/homebrew/bin/yarn npm: 10.7.0 - ~/.nvm/versions/node/v20.15.1/bin/npm pnpm: 9.6.0 - ~/.nvm/versions/node/v20.15.1/bin/pnpm

Describe the bug

I used two editors in different pages. Now they work okay but the second editor shows the word count of the first when I run:

editor.storage.characterCount.words()

This is weird because editor.storage.markdown.getMarkdown() gives the correct data.

Link to reproduction

-

To reproduce

-

Additional information

No response

sushilldhakal commented 3 weeks ago

Maybe you are saving it to you local storage. I did the same thing but its working fine.