oeyoews / tiddlywiki-codemirror6

Your Next TiddlyWiki5 Editor: Codemirror6
https://tiddlywiki-codemirror6.vercel.app/#%24%3A%2Fplugins%2Foeyoews%2Ftiddlywiki-codemirror-6
MIT License
13 stars 0 forks source link

Compatibility problem with LanguageTool firefox/chromium plugin #69

Open dionisos2 opened 5 months ago

dionisos2 commented 5 months ago

When this extension is installed : https://languagetool.org/fr I get a lot of error messages. I share it mostly so people not lose hours trying to understand what is going on.

How to reproduce

We can go at : https://oeyoews.github.io/tiddlywiki-codemirror6/#%24%3A%2Fplugins%2Foeyoews%2Ftiddlywiki-codemirror-6

Then create a new tiddler and paste this in it :

\`\`\`html
test
\`\`\`

\`\`\`html
test
\`\`\`

\`\`\`html
test
\`\`\`

After this, open the editor in full-screen, and click many times on the "show preview bane" button.

It will show this error in a popup:

Internal JavaScript Error
Well, this is embarrassing. It is recommended that you restart TiddlyWiki by refreshing your browser
ResizeObserver loop completed with undelivered notifications.

internal_javascript_error

After this error happen a first time, it will happen each time a line is deleted.

oeyoews commented 5 months ago

This browser extension will modify some nodes of the current web page, causing this problem. This is very common for tiddlywiki, especially language browser extensions. Sometimes even using Google Translate will cause tiddlywiki to report an error. The cause of the error is difficult to find, so error capture is temporarily unavailable. There is currently no good solution, other than disabling web pages that use tiddlywiki. Here are some related links

https://discuss.codemirror.net/t/resizeobserver-loop-completed-with-undelivered-notifications/7300

https://github.com/codemirror/dev/issues/1283

oeyoews commented 5 months ago

I did reproduce this, but the problem didn't occur on my own website, which is strange. I'm not sure if one of my own plugins accidentally fixed this problem.

Can you test the bug on this link? press alt-j to create new tiddler.

dionisos2 commented 5 months ago

I did reproduce this, but the problem didn't occur on my own website, which is strange. I'm not sure if one of my own plugins accidentally fixed this problem.

Can you test the bug on this link? press alt-j to create new tiddler.

I tried a lot but didn’t manage to reproduce it on your site.

It isn’t the same thing, but I get this error when I open it and when the plugin Dark Reader is activated :

Internal JavaScript Error
Well, this is embarrassing. It is recommended that you restart TiddlyWiki by refreshing your browser
TypeError: WeakMap key undefined must be an object or an unregistered symbol
dionisos2 commented 5 months ago

This browser extension will modify some nodes of the current web page, causing this problem. This is very common for tiddlywiki, especially language browser extensions. Sometimes even using Google Translate will cause tiddlywiki to report an error. The cause of the error is difficult to find, so error capture is temporarily unavailable. There is currently no good solution, other than disabling web pages that use tiddlywiki. Here are some related links

https://discuss.codemirror.net/t/resizeobserver-loop-completed-with-undelivered-notifications/7300

codemirror/dev#1283

Thanks for your answer. I think I just deactivate the LanguageTool for TiddlyWiki and wait. With some luck some futures versions will fix it. (at least others will know where it could come from, it was hard to find it)

oeyoews commented 5 months ago

In addition, you can use styles to hide this error pop-up window. @dionisos2

https://tiddlywiki-starter-kit.vercel.app/#%24%3A%2Fplugins%2Foeyoews%2Fneotw-error-better