Sha256: 6790deb264ee0dcd34290f19a34ae8b161ab037892854706e736416fbadd5d41

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.5.0 spec/rails_app/app/controllers/posts_controller.rb