Debugging Angular/Rails on iOS

A couple of findings while debugging a relatively large Rails backed AngularJS project on an iPad Air 2.

Not connecting over LAN

This isn’t iOS specific. By default, in development mode, rails only allows connections to localhost (which is not accessible from other machines or users). This is solved by binding rails to

  rails s -b

Too Many JS files

Both Safari and Chrome on the tablet would stop loading JS files after a while (couple hundred). To work around this I adjusted rails to concatenate the compiled Javascript files.

  # config/environment/development.rb

  # change
  config.assets.debug = true
  # to
  config.assets.debug = false

And then reload the server.