I am new to ruby gems and I have tried to find information about how to compile slim to html. There is a slimrb
command, but it did not work. How do I convert a slim file to a html file?
How to convert slim to html?
4.3k views Asked by tom At
2
There are 2 answers
0
On
Shouichi's answer is what you're looking for.
However from your comment, I understand you also want to redirect the output to a file (the .html file). The way this can be done depends on the shell you're using. For example in (ba)sh you could do it like this:
slimrb template.slim -l '{"message": "hello"}' > template.html
I assume local variables are missing. In that case, give them with
-l
option. For example,