Open
Description
Hi, I have the following HAML:
!!! 5
%html.no-js{:lang => "en"}
%head
%title Our Awesome Haml Template
%body
%p Abstracting HTML since 2006
But it's outputting the following error message in the generated file:
<pre class='error'>TypeError: undefined is not a function
at eval (eval at <anonymous> (/Users/mbiz/www/suau/node_modules/haml/lib/haml.js:595:29), <anonymous>:2:15)
at Function.<anonymous> (/Users/mbiz/www/suau/node_modules/haml/lib/haml.js:595:11)
at execute (/Users/mbiz/www/suau/node_modules/haml/lib/haml.js:602:8)
at Function.render (/Users/mbiz/www/suau/node_modules/haml/lib/haml.js:587:12)
at hamlStream (/Users/mbiz/www/suau/node_modules/gulp-haml/index.js:31:6)
at wrappedMapper (/Users/mbiz/www/suau/node_modules/map-stream/index.js:84:19)
at Stream.stream.write (/Users/mbiz/www/suau/node_modules/map-stream/index.js:96:21)
at write (/Users/mbiz/www/suau/node_modules/gulp/node_modules/vinyl-fs/node_modules/through2/node_modules/readable-stream/lib/_stream_readable.js:623:24)
at flow (/Users/mbiz/www/suau/node_modules/gulp/node_modules/vinyl-fs/node_modules/through2/node_modules/readable-stream/lib/_stream_readable.js:632:7)
at DestroyableTransform.pipeOnReadable (/Users/mbiz/www/suau/node_modules/gulp/node_modules/vinyl-fs/node_modules/through2/node_modules/readable-stream/lib/_stream_readable.js:664:5)</pre>
It seems to work if I remove the {:lang => "en"}
part, but I want to put a lang attribute here, so removing it is not an option.
Also, if it helps, here's how I'm declaring my gulpfile task:
gulp.task('haml', function () {
return gulp.src('src/haml/**/*.haml')
.pipe(haml({ext: '.html'}))
// .pipe(prettify({indent_char: ' ', indent_size: 4}))
.pipe(gulp.dest('./'));
});
Anyway, let me know if you need any more info :) Thanks
Metadata
Metadata
Assignees
Labels
No labels