Browse Source

Make fortunes template match spec

Richard Nienaber 11 years ago
parent
commit
784074f9a6

+ 1 - 0
frameworks/Ruby/sinatra/hello_world.rb

@@ -6,6 +6,7 @@ ActiveRecord::Base.logger = nil
 set :activerecord_logger, nil
 set :activerecord_logger, nil
 set :static, false
 set :static, false
 set :template_engine, :slim
 set :template_engine, :slim
+Slim::Engine.set_default_options format: :html5, sort_attrs: false
 
 
 # Specify the encoder - otherwise, sinatra/json inefficiently
 # Specify the encoder - otherwise, sinatra/json inefficiently
 # attempts to load one of several on each request
 # attempts to load one of several on each request

+ 3 - 5
frameworks/Ruby/sinatra/views/fortunes.slim

@@ -1,9 +1,7 @@
 table
 table
-  thead
-    tr
-      th id
-      th message
-  tbody
+  tr
+    th id
+    th message
   - for fortune in @fortunes
   - for fortune in @fortunes
     tr
     tr
       td =fortune.id
       td =fortune.id