metalsmith / layouts

A metalsmith plugin for layouts
MIT License
116 stars 49 forks source link

SyntaxError: Assigning to rvalue (5:0) #112

Closed AndyOGo closed 7 years ago

AndyOGo commented 7 years ago

After moving form metalsmith-templates to metalsmith-layouts and replacing all template with layout inside all frontmatters, my build troughs:

SyntaxError: Assigning to rvalue (5:0) at Parser.pp.raise (/.../node_modules/acorn-globals/node_modules/acorn/dist/acorn.js:943:13) at Parser.pp.checkLVal (/.../node_modules/acorn-globals/node_modules/acorn/dist/acorn.js:1226:12) at Parser.pp.parseMaybeUnary (/.../node_modules/acorn-globals/node_modules/acorn/dist/acorn.js:192:22) at Parser.pp.parseExprOps (/.../node_modules/acorn-globals/node_modules/acorn/dist/acorn.js:151:19) at Parser.pp.parseMaybeConditional (/.../node_modules/acorn-globals/node_modules/acorn/dist/acorn.js:133:19) at Parser.pp.parseMaybeAssign (/.../node_modules/acorn-globals/node_modules/acorn/dist/acorn.js:110:19) at Parser.pp.parseExpression (/.../node_modules/acorn-globals/node_modules/acorn/dist/acorn.js:86:19) at Parser.pp.parseStatement (/.../node_modules/acorn-globals/node_modules/acorn/dist/acorn.js:1750:23) at Parser.pp.parseTopLevel (/.../node_modules/acorn-globals/node_modules/acorn/dist/acorn.js:1666:21) at Parser.parse (/.../node_modules/acorn-globals/node_modules/acorn/dist/acorn.js:1636:17) at Object.parse (/.../node_modules/acorn-globals/node_modules/acorn/dist/acorn.js:905:44) at reallyParse (/.../node_modules/acorn-globals/index.js:30:18) at findGlobals (/.../node_modules/acorn-globals/index.js:45:11) at addWith (/.../node_modules/with/index.js:45:14) at parse (/.../node_modules/jade/lib/index.js:149:9) at Object.exports.compile (/.../node_modules/jade/lib/index.js:205:16)

I created an Issue at acorn.js repo too. https://github.com/ternjs/acorn/issues/473

ismay commented 7 years ago

It doesn't look like this is a problem with metalsmith-layouts. If you want me to take a closer look please create an example repo that reproduces the error. That way I can see what's going on exactly. Closing this, but please let me know if the example repo is up.

AndyOGo commented 7 years ago

@ismay IT's fine for me to close it. We found that upgrading from jade to pug "fixed" the issue for us. So I guess it can be safely ignored.