Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

Already on GitHub? Sign in to your account

template helpers work well with current version of Tilt #9

Merged
merged 1 commit into from Dec 1, 2011

Conversation

Projects
None yet
2 participants
Contributor

udzura commented Dec 1, 2011

Hi, rkh

I found that almost-sinatra.rb's template helpers mayn't work well with current version of Tilt.
So I created a patch.

Thank you!

rkh added a commit that referenced this pull request Dec 1, 2011

Merge pull request #9 from udzura/patch-1
template helpers work well with current version of Tilt

@rkh rkh merged commit 9b72a89 into rkh:master Dec 1, 2011

Owner

rkh commented Dec 1, 2011

I'm curious: How did you run into this issue?

Contributor

udzura commented Dec 1, 2011

I was interested in your almost-sinatra.rb code so I've analyzed the spaghetti.
I ran the sinatra-ish code below:

require 'haml'
require './almost_sinatra'

get '/' do
  "foobar"
end

get '/hi' do
  @title = "hello"
  haml :index
end

__END__

@@ index
%h1= @title
%p hello

Then I got the error undefined method 'new' for [Tilt::HamlTemplate]:Array,
and I found Tilt.mappings returns a String => Array of Engines hash.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment