Search code examples
htmlruby-on-railsviewhamlmissing-template

Rails Missing Template Error


I got the following error when trying to run my Rails server:

 ActionView::MissingTemplate (Missing template pages/index, application/index with {:locale=>[:en], :formats=>[:html], :handlers=>[:erb, :builder, :raw, :ruby, :coffee, :jbuilder]}. Searched in:

Solution

  • The problem (which has happened to me on 2 occasions so I thought I would share the answer for reference) is that I forgot to add the haml gem. Silly problem that cost me way more time than it should have.