no such file to load — pdfkit (LoadError)

Problem
You are trying to use the pdfkit (here) in your rails application, and you configure it according to the configuration options for the rails 2.x in the config/environment.rb file. Although the application works, when you are trying to use the console you get the error:

no such file to load -- pdfkit (LoadError)

Solution
Make sure that:

require 'pdfkit'
in the config/environment.rb file comes after the line:

require File.join(File.dirname(__FILE__), 'boot')