jekyll-minifier
jekyll-minifier copied to clipboard
Unexpected token errors
Hello I am making a website using Jekyll and Foundation 6. After install I got an error that I am unable to make sense of. Can you explain to me what is happening in the console after I did jekyll serve
. Here is my error:
`jekyll 3.4.2 | Error: Unexpected token: name (Abide) (line: 10, col: 6, pos: 91)
Error at new JS_Parse_Error (/private/var/folders/x1/qjqh58fs0kjdspmhldlvvzf80000gn/T/execjs20170417-27073-x7pzazjs:2659:11936) at js_error (/private/var/folders/x1/qjqh58fs0kjdspmhldlvvzf80000gn/T/execjs20170417-27073-x7pzazjs:2659:12155) at croak (/private/var/folders/x1/qjqh58fs0kjdspmhldlvvzf80000gn/T/execjs20170417-27073-x7pzazjs:2659:20622) at token_error (/private/var/folders/x1/qjqh58fs0kjdspmhldlvvzf80000gn/T/execjs20170417-27073-x7pzazjs:2659:20759) at unexpected (/private/var/folders/x1/qjqh58fs0kjdspmhldlvvzf80000gn/T/execjs20170417-27073-x7pzazjs:2659:20847) at semicolon (/private/var/folders/x1/qjqh58fs0kjdspmhldlvvzf80000gn/T/execjs20170417-27073-x7pzazjs:2659:21320) at simple_statement (/private/var/folders/x1/qjqh58fs0kjdspmhldlvvzf80000gn/T/execjs20170417-27073-x7pzazjs:2659:24179) at /private/var/folders/x1/qjqh58fs0kjdspmhldlvvzf80000gn/T/execjs20170417-27073-x7pzazjs:2659:22152 at /private/var/folders/x1/qjqh58fs0kjdspmhldlvvzf80000gn/T/execjs20170417-27073-x7pzazjs:2659:21493 at block_ (/private/var/folders/x1/qjqh58fs0kjdspmhldlvvzf80000gn/T/execjs20170417-27073-x7pzazjs:2659:26198)`
I'm having the same problem. I got:
jekyll 3.4.3 | Error: Unexpected token: punc ()) (line: 152, col: 1, pos: 3508)
I was able to laboriously guess and check which file it came from, but it would be super helpful if you added the filename to the output.
Thanks for your reports, I'll look into these errors and try to get them resolved.
@malford89 @ellisonch @digitalsparky
I got this error when I used let
vs. var
for my variables. The minified didn't like let
so I changed everything back to var
and it fixed my issue.
I'm also receiving this issue, as well as problems with arrow functions and back-quote string interpolation. Seems the minifier doesn't like ES6 syntax.
I'm having this issue too... 😭