Hello
I try to get haml working without the gem with sinatra (Heroku doesn't allow gem install, as far as I know)
What I've done so far:
clone the haml git repo inside my project
add : require 'haml/lib/haml.rb' to my sinatra main file
the following works:
get '/test' do
Haml::Engine.new('%p test').render
end
but the following doesn't:
get '/test2' do
haml :my_template
end
I get the error :
NoMethodError - undefined method each' for nil:NilClass
(haml):20:in
render'
./haml/lib/haml/engine.rb:152:in `render'
./haml/lib/haml/engine.rb:152:in `instance_eval'
./haml/lib/haml/engine.rb:152:in `render' ...
Is there any other files to require ? Any ideas ?