App to calculate 15th C. paper sizes based on page dimensions.
Clone, install gems, and start the application:
git clone [email protected]:demery/paper-sizer.git
cd paper-sizer
bundle install # see below on bundler
rackup # start the app
Go to http://localhost:9292 to see the app!
To install all bundler:
gem install bundler
The work is done by app.rb
. The user inputs data on the form at the /
route (the views/index.erb
template):
get '/' do
erb :index
end
When user submits the form the data is posted to the /sizeit
route:
post '/sizeit' do
erb :sizeit, locals: params
end
The page displayed to the user is built from the views/sizeit.erb
template.
To add functionality to the application edit the /sizeit
action and the
views/sizeit.erb
template.