Sha256: 08c8e249279efc4299aa870a82fc95b0f2b9a68e3bbf5c57808c818332895206

Contents?: true

Size: 616 Bytes

Versions: 17

Compression:

Stored size: 616 Bytes

Contents

require "connection_pool"
require_relative "server_rendering_pool/exec"
require_relative "server_rendering_pool/node"

# Based on the react-rails gem.
# None of these methods should be called directly.
# See app/helpers/react_on_rails_helper.rb
module ReactOnRails
  module ServerRenderingPool
    class << self
      def pool
        if ReactOnRails.configuration.server_render_method == "NodeJS"
          ServerRenderingPool::Node
        else
          ServerRenderingPool::Exec
        end
      end

      def method_missing(sym, *args, &block)
        pool.send sym, *args, &block
      end
    end
  end
end

Version data entries

17 entries across 17 versions & 1 rubygems

Version Path
react_on_rails-6.0.5 lib/react_on_rails/server_rendering_pool.rb
react_on_rails-6.0.4 lib/react_on_rails/server_rendering_pool.rb
react_on_rails-6.0.3 lib/react_on_rails/server_rendering_pool.rb
react_on_rails-6.0.2 lib/react_on_rails/server_rendering_pool.rb
react_on_rails-6.0.1 lib/react_on_rails/server_rendering_pool.rb
react_on_rails-6.0.0 lib/react_on_rails/server_rendering_pool.rb
react_on_rails-6.0.0.rc.6 lib/react_on_rails/server_rendering_pool.rb
react_on_rails-6.0.0.rc.5 lib/react_on_rails/server_rendering_pool.rb
react_on_rails-6.0.0.rc.4 lib/react_on_rails/server_rendering_pool.rb
react_on_rails-6.0.0.rc3 lib/react_on_rails/server_rendering_pool.rb
react_on_rails-6.0.0.rc.2 lib/react_on_rails/server_rendering_pool.rb
react_on_rails-6.0.0.rc.1 lib/react_on_rails/server_rendering_pool.rb
react_on_rails-6.0.0.beta.5 lib/react_on_rails/server_rendering_pool.rb
react_on_rails-6.0.0.beta.4 lib/react_on_rails/server_rendering_pool.rb
react_on_rails-6.0.0.beta.3 lib/react_on_rails/server_rendering_pool.rb
react_on_rails-6.0.0.beta.2 lib/react_on_rails/server_rendering_pool.rb
react_on_rails-6.0.0.beta.1 lib/react_on_rails/server_rendering_pool.rb