Closed BoPeng closed 2 years ago
easymde.min.txt easymde.min1.txt
Steps to reproduce:
https://unpkg.com/easymde/dist/easymde.min.js
python -mrjsmin < easymde.min.js > easymde.min1.js
easymde.min1.js
easymde.min.js
Uncaught SyntaxError: nothing to repeat, easymde.min1.js:1:229168
Checking the location, the difference is the removal of two spaces in a regular expression, which looks wrong to me
{var r,i=n.align.length;for(r=0;r<i;r++)/^ *-+: *$/.test(n.align[r])?n.align[r]="right":/^ *:-+: *$/. {var r,i=n.align.length;for(r=0;r<i;r++)/^*-+:*$/.test(n.align[r])?n.align[r]="right":/^ *:-+: *$/.
Note that I was minifying a min.js file because it was concatenated with some other js files to be minified together.
Hi,
regexes in JS are a syntactical disaster :-(
Duplicate of #17
Fixed in 1.2.0
easymde.min.txt easymde.min1.txt
Steps to reproduce:
https://unpkg.com/easymde/dist/easymde.min.js
python -mrjsmin < easymde.min.js > easymde.min1.js
easymde.min1.js
instead ofeasymde.min.js
, chrome does not complain, firefox raises an errorChecking the location, the difference is the removal of two spaces in a regular expression, which looks wrong to me
Note that I was minifying a min.js file because it was concatenated with some other js files to be minified together.