Trying to use mathiasbynens/he to encode html entities in the browser, but after adding the library, the app has started getting syntax errors in Safari and Firefox.
The offending character seems to be a unicode character, that appears in the source after minification.
Here's the result of running the corresponding snippet of code in Babel's REPL with Babili enabled:
let a = { '\u2118':'wp' };
// becomes
'use strict';var a={℘:'wp'};
Visiting that link in Firefox 50.1.0 results in an "Illegal character error" in the REPL. Seeing as it works fine without Babili, I'm guessing this is a bug, rather than a deliberate constraint.
Pretty sure it happens in babel-plugin-transform-property-literals as it turns the string into a literal key.
Trying to use mathiasbynens/he to encode html entities in the browser, but after adding the library, the app has started getting syntax errors in Safari and Firefox.
The offending character seems to be a unicode character, that appears in the source after minification.
Here's the result of running the corresponding snippet of code in Babel's REPL with Babili enabled:
Visiting that link in Firefox 50.1.0 results in an "Illegal character error" in the REPL. Seeing as it works fine without Babili, I'm guessing this is a bug, rather than a deliberate constraint.
Pretty sure it happens in babel-plugin-transform-property-literals as it turns the string into a literal key.