DFBerry
DFBerry

Reputation: 2006

Ruby/Rails binding css for haml pages

I'm new to Rails (coming from .Net). My web app is supposed to pick up and include the /app/assets/stylesheets/application.css file. The haml file is displayed without the css markup and without any notation of including the css file.

This is a bare bones site with not many files. Where is the config to make sure the haml brings in the css file and displays the final page with css formatting?

Upvotes: 0

Views: 1672

Answers (2)

DFBerry
DFBerry

Reputation: 2006

Final solution is: change xxx_controller to inherit from ApplicationController instead of ActionController::Base.

Upvotes: 0

Nash Bridges
Nash Bridges

Reputation: 2378

Layout which is used by your view has to include = stylesheet_link_tag "application". If you haven't changed anything, it must be in app/views/layouts/application.html.haml.

Upvotes: 1

Related Questions