Closed XhmikosR closed 9 years ago
In case you want to try, here's the source
svn checkout https://svn.code.sf.net/p/stefanstools/code/trunk/www/ stexbar-www
Is it because your include is including header.html and your trying to use bottomHtml in the footer, which is an empty global?
Hmm, damn it, you are right. :)
This gets replaced, sort of
@@include("_includes/footer.html", {
"bottomHtml": "<script src=\"/js/prettify/prettify.js\"></script>\n<script>window.onload = prettyPrint();</script>"
)}
But I end up with
@@include("_includes/footer.html", {
"bottomHtml": "<script src=\"/js/prettify/prettify.js\"></script>\n<script>window.onload = prettyPrint();</script>"
)}
in the replaced html.
Here's my local patch (sorry, it's a little messy, but you know, SVN :p) https://gist.github.com/XhmikosR/5eb919a788b6264fb302
All right, a wrongly placed brace after the parentheses caused this :/
Thanks for all your help!
Hey, @alanshaw.
I have a project I use grunt-include-replace. My config is
Everything works fine, except for
bottomHtml
; it's always empty. Here's how I call it from an HTML file:and in my footer.html I have
If I set
bottomHtml
to anything in Gruntfile globals, then it gets replaced just fine too.Any ideas?