Sha256: 2e533eca00cf573149ffe921fd752ba1bf2ff6e7a2d7ce1195a14ed1d200dbc2

Contents?: true

Size: 344 Bytes

Versions: 31

Compression:

Stored size: 344 Bytes

Contents

# frozen_string_literal: true

module ReactOnRails
  module TestHelper
    def self.launch_node
      return unless ReactOnRails.configuration.server_render_method == "NodeJS"

      path = "#{::Rails.root}/client/node"
      puts "Launching NodeJS server at #{path}"
      system("cd #{path} && yarn start &")
      sleep(1)
    end
  end
end

Version data entries

31 entries across 31 versions & 1 rubygems

Version Path
react_on_rails-10.1.4 lib/react_on_rails/test_helper/node_process_launcher.rb
react_on_rails-10.1.3 lib/react_on_rails/test_helper/node_process_launcher.rb
react_on_rails-10.1.1 lib/react_on_rails/test_helper/node_process_launcher.rb
react_on_rails-10.1.0 lib/react_on_rails/test_helper/node_process_launcher.rb
react_on_rails-10.0.2 lib/react_on_rails/test_helper/node_process_launcher.rb
react_on_rails-10.0.1 lib/react_on_rails/test_helper/node_process_launcher.rb
react_on_rails-10.0.0 lib/react_on_rails/test_helper/node_process_launcher.rb
react_on_rails-9.0.3 lib/react_on_rails/test_helper/node_process_launcher.rb
react_on_rails-9.0.2 lib/react_on_rails/test_helper/node_process_launcher.rb
react_on_rails-9.0.1 lib/react_on_rails/test_helper/node_process_launcher.rb
react_on_rails-9.0.0 lib/react_on_rails/test_helper/node_process_launcher.rb
react_on_rails-9.0.0.rc.0 lib/react_on_rails/test_helper/node_process_launcher.rb
react_on_rails-9.0.0.beta.12 lib/react_on_rails/test_helper/node_process_launcher.rb
react_on_rails-9.0.0.beta.11 lib/react_on_rails/test_helper/node_process_launcher.rb
react_on_rails-9.0.0.beta.10 lib/react_on_rails/test_helper/node_process_launcher.rb
react_on_rails-9.0.0.beta.9 lib/react_on_rails/test_helper/node_process_launcher.rb
react_on_rails-9.0.0.beta.8 lib/react_on_rails/test_helper/node_process_launcher.rb
react_on_rails-9.0.0.beta.7 lib/react_on_rails/test_helper/node_process_launcher.rb
react_on_rails-9.0.0.beta.6 lib/react_on_rails/test_helper/node_process_launcher.rb
react_on_rails-9.0.0.beta.5 lib/react_on_rails/test_helper/node_process_launcher.rb