我在Rails 4应用程序中使用High Voltage作为静态页面。我想指定一个静态主页as outlined here但是我在服务器启动时遇到以下错误:
undefined method `configure' for HighVoltage:Module (NoMethodError)
我在config / initializers中有一个high_voltage.rb文件,所以无法理解这里出了什么问题。除此之外,高压工作正常。
更新:
Gemfile包含以下行:
gem 'high_voltage'
Gemfile.lock的:
high_voltage (2.0.0)
high_voltage.rb:
HighVoltage.configure do |config|
config.home_page = 'home'
end
答案 0 :(得分:1)