Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
tree: b7e75ec75c
Fetching contributors…

Cannot retrieve contributors at this time

20 lines (17 sloc) 0.615 kB
%w(action_controller/railtie coderay).each &method(:require)
run TheSmallestRailsApp ||= Class.new(Rails::Application) {
config.secret_token = routes.append { root to: 'hello#world' }.inspect
initialize!
}
class HelloController < ActionController::Base
def world
render inline: %Q{
<!DOCTYPE html>
<title>The Smallest Rails App</title>
<h3>I am the smallest rails app!</h3>
<p>Here is my source code:</p>
#{CodeRay.scan_file(__FILE__, :ruby).div(line_numbers: :table)}
<a href="https://github.com/artemave/thesmallestrailsapp.com">Make me smaller</a>
}
end
end
Jump to Line
Something went wrong with that request. Please try again.