Sha256: 58e4fdb856033b8ff858a55adeb08cb1b951925a24f5fbafb8788e24515d93d6

Contents?: true

Size: 390 Bytes

Versions: 1

Compression:

Stored size: 390 Bytes

Contents

class Post < Struct.new(:id); end

class PostsController < ApplicationController

  breadcrumb 'Home', :root_path, only: :index

  def index
    breadcrumb 'All Posts', posts_path
  end

  def show
    @post = ::Post.new(1)
  end

  def new
    breadcrumb 'New Post', new_post_path
  end

  def create
    breadcrumb 'New Post', new_post_path, force: true
    render action: :new
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
loaf-0.4.0 spec/rails_app/app/controllers/posts_controller.rb