creationix / haml-js

Haml ported to server-side Javascript. This is a traditional server-side templating language. Tested with node-js
MIT License
900 stars 109 forks source link

bug: conditional comments don't work #80

Open ghost opened 10 years ago

ghost commented 10 years ago

I try to compile following: / [if lt IE9] %script{src: "http://html5shiv.googlecode.com/svn/trunk/html5.js"}

but I have a syntaxError. If I really have a syntax problem, please, give me an advice to solve this.

Here error message is:

SyntaxError: Unexpected identifier at Function. (D:\Projects\omnigena\node_modules\gulp-haml\node_modules\haml\lib\haml.js:595:29) at execute (D:\Projects\omnigena\node_modules\gulp-haml\node_modules\haml\lib\haml.js:602:8) at Function.render (D:\Projects\omnigena\node_modules\gulp-haml\node_modules\haml\lib\haml.js:587:12) at hamlStream (D:\Projects\omnigena\node_modules\gulp-haml\index.js:15:21) at wrappedMapper (D:\Projects\omnigena\node_modules\gulp-haml\node_modules\map-stream\index.js:84:19) at Stream.stream.write (D:\Projects\omnigena\node_modules\gulp-haml\node_modules\map-stream\index.js:96:21) at Stream.ondata (stream.js:51:26) at Stream.EventEmitter.emit (events.js:95:17) at queueData (D:\Projects\omnigena\node_modules\gulp\node_modules\vinyl-fs\node_modules\map-stream\index.js:43:21) at queueData (D:\Projects\omnigena\node_modules\gulp\node_modules\vinyl-fs\node_modules\map-stream\index.js:56:14)

Thanks.

PragmaticEd commented 7 years ago

Seriously? No solution after so many years? This also happen if you add multi-dashed attributes, like: meta{'data-test': 123}