Manifest version 3 migration is block by a content script problem:
Some dependencies(probably @uiw/react-codemirror and related packages) in Note.tsx contain non utf8 characters, and browser content-script does not allow that.
A solution is to use another code-mirror alternative, but I cannot find a good one with all the themes we already provide, and to make the extension backwards compatible, I want to keep all the themes. There is a @uiw/react-md-editor looks good, but also have utf8 problem.
Another solution is to use iframe as suggested in this issue, but in my use case, I cannot use iframe as the root for all sticky notes, that will make parent window not usable. If I use an iframe for each created note, it's hard to impl and may make browser laggy.
A third solution is to replace/remove all no-utf8 characters, I tried to use a custom vite plugin, there are some characters that are easy to replace, but others are not easy to do so, coz it will affect runtime logic and cause runtime errors.
pr: https://github.com/qiweiii/markdown-sticky-notes/pull/43
Manifest version 3 migration is block by a content script problem:
Some dependencies(probably
@uiw/react-codemirror
and related packages) inNote.tsx
contain non utf8 characters, and browser content-script does not allow that.A solution is to use another code-mirror alternative, but I cannot find a good one with all the themes we already provide, and to make the extension backwards compatible, I want to keep all the themes. There is a @uiw/react-md-editor looks good, but also have utf8 problem.
Another solution is to use iframe as suggested in this issue, but in my use case, I cannot use iframe as the root for all sticky notes, that will make parent window not usable. If I use an iframe for each created note, it's hard to impl and may make browser laggy.
A third solution is to replace/remove all no-utf8 characters, I tried to use a custom vite plugin, there are some characters that are easy to replace, but others are not easy to do so, coz it will affect runtime logic and cause runtime errors.