Class: Stitch::Server

Inherits:
Object
  • Object
show all
Defined in:
lib/stitch/server.rb

Instance Method Summary collapse

Constructor Details

#initialize(options = {}) ⇒ Server

Returns a new instance of Server.



3
4
5
# File 'lib/stitch/server.rb', line 3

def initialize(options = {})
  @package = Package.new(options)
end

Instance Method Details

#call(env) ⇒ Object



7
8
9
# File 'lib/stitch/server.rb', line 7

def call(env)
  [200, {"Content-Type" => "text/javascript"}, [@package.compile]]
end