Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Sign up for free
Menu
Search
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Pricing
Search
Sign in
Sign up for free
shinosakarb #11 Rails 4 Pattenrs
Search
murajun1978
December 20, 2014
Programming
200
1
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
shinosakarb #11 Rails 4 Pattenrs
murajun1978
December 20, 2014
More Decks by murajun1978
See All by murajun1978
変化を楽しむエンジニアリング ~ いままでとこれから ~
murajun1978
0
1.5k
How to Enjoy the Murajun’s Style
murajun1978
0
120
Building Tebukuro with Hotwire and Rails
murajun1978
0
1.6k
Zeitwerk integration in Rails 6.0
murajun1978
0
150
Efficient development with GraphQL
murajun1978
0
340
Effective Debugging Apps in VS Code
murajun1978
1
1k
tebukuro
murajun1978
0
150
Shinosaka.rb #17 Hands on
murajun1978
0
76
New Features in Rails 4.2
murajun1978
0
980
Other Decks in Programming
See All in Programming
Kiroで創り、AgentCoreで繋ぐ!AWSで実践する「AI-DLC」から「AIエージェント統合」までの最新地図
licux
3
470
【DroidKaigi 2026】「アクセシビリティを利用するとき、 アクセシビリティもまたこちらを利用している」 〜マルウェアによる攻撃と防衛について〜
halunoyo
0
430
ソフトウェアラスタライザ
fadis
1
800
Gmail/Google DriveをトリガーにAIエージェントを動かそう! / Run AI agents with Gmail/Google Drive as triggers!
har1101
3
490
DroidKaigi 2026 「個人開発という実験場: Android エンジニアが手にする4つの自由」
slashnephy
0
230
数年滞っていたダークモード対応をおよそ2週間で完了させる
chigichan24
0
700
Swift愛好会と私(ウホーイ) / Swift Fan Club and Uhooi
uhooi
0
150
ハーネス設計入門 〜プロンプト、コンテキストの次〜
kinopeee
55
37k
Omarchy Tokyo やると聞いて UMPC 買ってセットアップしてきた
mtsmfm
0
130
Swift愛好会100回記念 第1回を振り返る
jollyjoester
0
120
Hello, Hiroshima Geospatial Data! — Exploring DoboX with Python
ra0kley
0
180
まだ間に合う!今年の夏こそSchemeのマクロ展開器を完全理解!
omasanori
0
650
Featured
See All Featured
Building Better People: How to give real-time feedback that sticks.
wjessup
370
20k
Designing Powerful Visuals for Engaging Learning
tmiket
1
540
Jamie Indigo - Trashchat’s Guide to Black Boxes: Technical SEO Tactics for LLMs
techseoconnect
PRO
0
660
Navigating Team Friction
lara
192
16k
Ethics towards AI in product and experience design
skipperchong
2
370
Mozcon NYC 2025: Stop Losing SEO Traffic
samtorres
1
520
New Earth Scene 8
popppiees
3
2.5k
Marketing to machines
jonoalderson
1
5.8k
Producing Creativity
orderedlist
PRO
348
41k
How to optimise 3,500 product descriptions for ecommerce in one day using ChatGPT
katarinadahlin
PRO
2
3.8k
Un-Boring Meetings
codingconduct
0
410
Become a Pro
speakerdeck
PRO
31
6.2k
Transcript
Rails 4 Patterns Shinosaka.rb #11
me @murajun1978
Rails 4.2.0 has been released!
new goodies ActionMailer #deliver_later Active Job Web Console Good! Adequate
Record
Agenda • ActiveRecord::Callbacks • Scope • ActiveSupport::Concern • Decorator •
ActiveDecorator vs Draper • Helper
Fat Controller
Fat Controller
ActiveRecord::Callbacks
Scope NoMethodError!!
Scope
Scope
Fat Model
ActiveSupport::Concern app/models/concerns/… Class method duplicate :(
Decorator ActiveDecorator view logic… :( $ rails g decorator Post
app/decorators/…
Decorator Which do you like? ActiveDecorator Draper https://github.com/drapergem/draper https://github.com/amatsuda/active_decorator
Helper content_tag_for <tr id="post_123" class=“post ..”>…</tr> http://localhost/posts#post_123