Sha256: 6eca1ab3b0fad4bf534660ed95d3ed427d1523b56aecb4f4e7bf504f586d2deb

Contents?: true

Size: 320 Bytes

Versions: 29

Compression:

Stored size: 320 Bytes

Contents

module Sinatra
  module WebSocketIO
    module Helpers

      def websocketio_js
        "#{env['rack.url_scheme']}://#{env['HTTP_HOST']}#{env['SCRIPT_NAME']}/websocketio/websocketio.js"
      end

      def websocketio_url
        "ws://#{env['SERVER_NAME']}:#{WebSocketIO.options[:port]}"
      end

    end
  end
end

Version data entries

29 entries across 29 versions & 1 rubygems

Version Path
sinatra-websocketio-0.4.1 lib/sinatra-websocketio/helpers.rb
sinatra-websocketio-0.4.0 lib/sinatra-websocketio/helpers.rb
sinatra-websocketio-0.3.9 lib/sinatra-websocketio/helpers.rb
sinatra-websocketio-0.3.7 lib/sinatra-websocketio/helpers.rb
sinatra-websocketio-0.3.6 lib/sinatra-websocketio/helpers.rb
sinatra-websocketio-0.3.5 lib/sinatra-websocketio/helpers.rb
sinatra-websocketio-0.3.4 lib/sinatra-websocketio/helpers.rb
sinatra-websocketio-0.3.3 lib/sinatra-websocketio/helpers.rb
sinatra-websocketio-0.3.2 lib/sinatra-websocketio/helpers.rb
sinatra-websocketio-0.3.1 lib/sinatra-websocketio/helpers.rb
sinatra-websocketio-0.3.0 lib/sinatra-websocketio/helpers.rb
sinatra-websocketio-0.2.9 lib/sinatra-websocketio/helpers.rb
sinatra-websocketio-0.2.8 lib/sinatra-websocketio/helpers.rb
sinatra-websocketio-0.2.7 lib/sinatra-websocketio/helpers.rb
sinatra-websocketio-0.2.6 lib/sinatra-websocketio/helpers.rb
sinatra-websocketio-0.2.5 lib/sinatra-websocketio/helpers.rb
sinatra-websocketio-0.2.4 lib/sinatra-websocketio/helpers.rb
sinatra-websocketio-0.2.3 lib/sinatra-websocketio/helpers.rb
sinatra-websocketio-0.2.2 lib/sinatra-websocketio/helpers.rb
sinatra-websocketio-0.2.1 lib/sinatra-websocketio/helpers.rb