Home

Awesome

Haml::More and Sass::More

Adds more functionality to Haml and Sass. Haml helpers detect if called from another context, so they are usable with Erb and friends.

BigBand

Haml::More and Sass::More are part of the BigBand stack. Check it out if you are looking for fancy Sinatra extensions.

Haml extensions

SassScript extensions

Usage with Sinatra

Classic style:

require "sinatra"
require "haml/more"

Modular:

require "sinatra/base"
require "haml/more"

class Foo < Sinatra::Base
  helpers Haml::More
end

Usage without Sinatra

Using just Sass::More (if you're in Merb or Rails):

# in some initializer or something
require "sass/more"

Without anything:

require "haml/more"
scope = Object.new
scope.extend Haml::More
puts Haml::Engine.new("%p some haml code").render(scope)