iamcal / oembed

The oEmbed Spec
http://oembed.com
MIT License
1.32k stars 651 forks source link

Avoid escaping slashes in JSON #483

Closed tomerle closed 3 years ago

iamcal commented 4 years ago

i understand what this change does, but not why. the output is already valid JSON

tomerle commented 4 years ago

Hi @iamcal,

Didn't mean to imply any validity issues. Just forgot to write my reasons of course.

I suggest the JS default might be more expected than the PHP default, since unescaped slashes are widely used in package.json files and many other examples. I also noticed the file is not minified and assumed it's for readability to help contributors lookup entries. Losing the slashed improves that and also enables copy-paste and searching for URLs as written in the YAML files.

Are those acceptable reasons to consider this? Any reasons for preferring the PHP default I'm missing?

iamcal commented 3 years ago

merged and site updated, thanks. changes will be reflected when caches expire in ~1hr