Make the Sinatra app directory aware.

This commit is contained in:
Darren Oakley
2012-06-18 16:00:14 +01:00
parent b53c961db2
commit 971cbb94f6
25 changed files with 468 additions and 127 deletions
+3 -5
View File
@@ -1,16 +1,14 @@
module Precious
module Views
class Page < Layout
include HasPage
attr_reader :content, :page, :header, :footer
DATE_FORMAT = "%Y-%m-%d %H:%M:%S"
DEFAULT_AUTHOR = 'you'
def title
@page.title
end
def format
@page.format.to_s
@page.url_path.gsub("-", " ")
end
def author