Module: Jammit

Defined in:
lib/jammit/sinatra.rb,
lib/jammit/middleware.rb

Overview

provides hook so you can run register Jammit in your

Defined Under Namespace

Modules: HelperOverrides Classes: Middleware

Class Method Summary collapse

Class Method Details

.registered(app) ⇒ Object



24
25
26
27
28
29
30
31
32
33
34
# File 'lib/jammit/sinatra.rb', line 24

def self.registered(app)
  app.helpers Jammit::Helper
  app.helpers Jammit::HelperOverrides

  app.use Jammit::Middleware

  # reload assets after every request (on development only)
  if app.development?
    app.before { Jammit.reload! }
  end
end