Permalink
Browse files

Code block spacing.

  • Loading branch information...
tristanoneil committed Sep 19, 2012
1 parent 93bd63c commit 17e9cb9e0b7928ac51d0ddc6297efe937fdab736
Showing with 9 additions and 18 deletions.
  1. +9 −18 index.html
View
@@ -48,8 +48,7 @@ <h2>An administration framework for Ruby on Rails</h2>
<section>
<section data-markdown>
<h1>The <span>Problem</span></h1>
- <pre><code class="ruby">
- class PostsController < ApplicationController
+ <pre><code class="ruby">class PostsController < ApplicationController
def update
@post = Post.find(params[:id])
@post.update_attributes(params[:post])
@@ -66,8 +65,7 @@ <h1>The <span>Problem</span></h1>
</section>
<section data-markdown>
<h1>The <span>Problem</span></h1>
- <pre><code class="ruby">
- <%= form_for(@post) do |f| %>
+ <pre><code class="ruby"><%= form_for(@post) do |f| %>
<%= f.text_field :title %>
<%= f.text_area :body %>
@@ -87,8 +85,7 @@ <h1>The <span>Problem</span></h1>
</section>
<section data-markdown>
<h1>The <span>Solution</span></h1>
- <pre><code class="ruby">
- ActiveAdmin.register Post do
+ <pre><code class="ruby">ActiveAdmin.register Post do
end
ActiveAdmin.register Page do
@@ -102,13 +99,11 @@ <h1>It's <span>Pretty</span></h1>
<section data-markdown>
<h1>Get <span>Started</span></h1>
<h3>Add to Gemfile</h3>
- <pre><code class="ruby">
- gem 'activeadmin'
+ <pre><code class="ruby">gem 'activeadmin'
</code></pre>
<h3>Run in CLI</h3>
- <pre><code class="bash">
- rails generate active_admin:install
+ <pre><code class="bash">rails generate active_admin:install
rails generate active_admin:resource [resource]
</code></pre>
</section>
@@ -118,8 +113,7 @@ <h1><span>D</span>omain <span>S</span>pecific <span>L</span>anguage</h1>
</section>
<section data-markdown>
<h1>Index <span>Views</span></h1>
- <pre><code class="ruby">
- index do
+ <pre><code class="ruby">index do
column :title
column :author
default_actions
@@ -135,8 +129,7 @@ <h1>Index <span>Views</span></h1>
</section>
<section data-markdown>
<h1>Show <span>Views</span></h1>
- <pre><code class="ruby">
- show do
+ <pre><code class="ruby">show do
h3 post.title
div do
markdown post.body
@@ -153,8 +146,7 @@ <h1>Show <span>Views</span></h1>
</section>
<section data-markdown>
<h1>Form <span>Definitions</span></h1>
- <pre><code class="ruby">
- form do |f|
+ <pre><code class="ruby">form do |f|
f.inputs "Post Details" do
f.input :title
f.input :author, :as => :select, :collection => ["Tristan O'Neil"]
@@ -168,8 +160,7 @@ <h1>Form <span>Definitions</span></h1>
</section>
<section data-markdown>
<h1>Controller <span>Definitions</span></h1>
- <pre><code class="ruby">
- controller do
+ <pre><code class="ruby">controller do
def update
# override default update action behavior.
end

0 comments on commit 17e9cb9

Please sign in to comment.