{"action":"closed","issue":{"url":"https://api.github.com/repos/Financial-Times/polyfill-service/issues/822","repository_url":"https://api.github.com/repos/Financial-Times/polyfill-service","labels_url":"https://api.github.com/repos/Financial-Times/polyfill-service/issues/822/labels{/name}","comments_url":"https://api.github.com/repos/Financial-Times/polyfill-service/issues/822/comments","events_url":"https://api.github.com/repos/Financial-Times/polyfill-service/issues/822/events","html_url":"https://github.com/Financial-Times/polyfill-service/issues/822","id":170327388,"number":822,"title":"Intl polyfill concatenation with Intl locale data polyfill causing syntax errors","user":{"login":"egoldblum","id":64733,"avatar_url":"https://avatars.githubusercontent.com/u/64733?v=3","gravatar_id":"","url":"https://api.github.com/users/egoldblum","html_url":"https://github.com/egoldblum","followers_url":"https://api.github.com/users/egoldblum/followers","following_url":"https://api.github.com/users/egoldblum/following{/other_user}","gists_url":"https://api.github.com/users/egoldblum/gists{/gist_id}","starred_url":"https://api.github.com/users/egoldblum/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/egoldblum/subscriptions","organizations_url":"https://api.github.com/users/egoldblum/orgs","repos_url":"https://api.github.com/users/egoldblum/repos","events_url":"https://api.github.com/users/egoldblum/events{/privacy}","received_events_url":"https://api.github.com/users/egoldblum/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":3,"created_at":"2016-08-10T04:51:07Z","updated_at":"2016-08-10T08:21:43Z","closed_at":"2016-08-10T08:21:43Z","body":"We noticed a large increase in errors right around UTC midnight today in safari when polyfilling `Intl` alongside `Intl.~locale.es` and `Intl.~locale.en`.\r\n\r\nThe problematic combined file can be fetched with the following.\r\n```\r\ncurl 'https://cdn.polyfill.io/v2/polyfill.min.js?features=Intl|always,Intl.~locale.en|always,Intl.~locale.es|always&unknown=polyfill' 'Accept-Encoding: gzip, deflate, sdch, br' -H 'User-Agent: Mozilla/5.0 (iPhone; CPU iPhone OS 9_3_3 like Mac OS X) AppleWebKit/601.1.46 (KHTML, like Gecko) Version/9.0 Mobile/13G34 Safari/601.1' -H 'Accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,*/*;q=0.8' \r\n```\r\n\r\nNot sure if this a polyfill-service bug or a bug in the polyfill itself ( https://github.com/andyearnshaw/Intl.js), but it looks like concatenation of https://github.com/andyearnshaw/Intl.js/blob/master/dist/Intl.min.js#L3 with additional files causes a syntax error in safari.\r\n\r\nhttps://github.com/andyearnshaw/Intl.js/blob/master/dist/Intl.min.js#L3 does not have a trailing newline and it does not appear that the polyfill-service concatenation enforces that joined files exist on new lines.\r\n\r\nWe were able to work around by splitting the concatenated request into separate requests, but this is obviously not ideal from a performance perspective."}}
{"actor":{"display_login":"triblondon"}}