build failure due to invalid utf-8 in source comments
First of all thanks for this, this a very useful pluging.
I can run my jekyll build with webmetion_io ok localy, but when it runs on the cloudflare Pages service, it fails with 'source sequence is illegal/malformed utf-8 (JSON::GeneratorError)'; I believe this is because at two places in comments a 'smart' apostrophe is encoded as \xE2\x80\x99, which is not valid JSON (\x is not a valid escape in JSON), but I have no idea at which point does the apostrope become encoded this way. But the source locations are,
// If there\xE2\x80\x99s a generic, add it there too
at https://github.com/aarongustafson/jekyll-webmention_io/blob/7d14638db4080b55d36f5d68532378d8d272ad07/lib/jekyll/assets/JekyllWebmentionIO.js#L192
and
* A re-tooling of Aaron Parecki\xE2\x80\x99s recommended JS for using the WebMention.io API
at https://github.com/aarongustafson/jekyll-webmention_io/blob/7d14638db4080b55d36f5d68532378d8d272ad07/lib/jekyll/assets/_utils.js#L4
The JSONs originates in the uglifier, but I think it is just wrapping what is pipped to it from this plugin, which AFAICT comes straight out of file io.
For me the easiest workaround is to manually deploy the js file, so that I don't have to run uglifier at on the target.
Pushed a fix for this to main. Let me know if it's resolved for you!
Would you be OK to release the fix?
I am terribly sorry for the late reply on this! Life is life-ing over here, as it tends to do.
I'll aim to get this released over the next week or so!
Well, I absolutely lied about that timeline, but I finally pushed 4.1.0 that includes this plus a few other fixes that have accumulated over time.