Closed multimeric closed 4 years ago
Surprisingly, using the copyright symbol in a string literal in source code is problematic (it was the last place I checked, in the process of debugging https://github.com/downforacross/downforacross.com/issues/90). This probably could've been avoided w/ a proper module bundler, so I'll try to get to setting that up for this project.
As part of the investigation / repro, I added window.copyrightSymbol = "©";
to the source code, then inspected the popup -- it became "©"
. I believe this is because the js source file is served with the incorrect mime type (or something along those lines -- unfortunately i'm not an expert in file encoding). I pushed a commit to fix this.
You're right that the source of the problem was the perceived encoding of guardian.js, not anything else. But I solved that I think more neatly by just adding <script src="loaders/guardian.js" charset="utf-8"></script>
to the HTML. When I view the extension source code in Chrome, it now no longer shows the wrong character.
You're right that the source of the problem was the perceived encoding of guardian.js, not anything else. But I solved that I think more neatly by just adding
<script src="loaders/guardian.js" charset="utf-8"></script>
to the HTML. When I view the extension source code in Chrome, it now no longer shows the wrong character.
That's a much neater solution, thanks.
Thanks for the merge. Although I've found a small bug that's equally frustrating. The dashes in the clues are being converted to the paragraph symbol. For example: https://downforacross.com/beta/game/215914-smub. I'm really not sure where the error is occurring in this case.
Can you publish a new version of the add-on with this change, please?
Yup, waiting for review!
@TMiguelT it's live!
Cheers!
Closed #9
I didn't get time for the big rewrite I was hoping for, but I believe this works.