shannonmoeller / gulp-hb

A sane Gulp plugin to compile Handlebars templates. Useful as a static site generator.

Home Page:http://npm.im/gulp-hb

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

importing inline css via helper

lubomirblazekcz opened this issue · comments

Hello,
I'm trying to import inline css via helper. eg. inline_css: fs.readFileSync('css/style.css','utf8')

But in the output the entities are converted.. example:

= to = 
& to &, 

is there any way to disable this?

Yep! Handlebars itself provides the solution. Use three curly braces instead of two:

<!-- insert escaped value (`=` to `&#x3D;`) -->
{{inline_css}}

<!-- insert raw value (`=` stays `=`) -->
{{{inline_css}}}

I totally forgot about that, thanks a lot!