Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
shinosakarb #11 Rails 4 Pattenrs
Search
murajun1978
December 20, 2014
Programming
1
180
shinosakarb #11 Rails 4 Pattenrs
murajun1978
December 20, 2014
Tweet
Share
More Decks by murajun1978
See All by murajun1978
変化を楽しむエンジニアリング ~ いままでとこれから ~
murajun1978
0
1.1k
How to Enjoy the Murajun’s Style
murajun1978
0
92
Building Tebukuro with Hotwire and Rails
murajun1978
0
1.5k
Zeitwerk integration in Rails 6.0
murajun1978
0
130
Efficient development with GraphQL
murajun1978
0
320
Effective Debugging Apps in VS Code
murajun1978
1
960
tebukuro
murajun1978
0
140
Shinosaka.rb #17 Hands on
murajun1978
0
67
New Features in Rails 4.2
murajun1978
0
960
Other Decks in Programming
See All in Programming
The free-lunch guide to idea circularity
hollycummins
0
340
S3ストレージクラスの「見える」「ある」「使える」は全部違う ─ 体験から見た、仕様の深淵を覗く
ya_ma23
0
980
Migration to Signals, Signal Forms, Resource API, and NgRx Signal Store @Angular Days 03/2026 Munich
manfredsteyer
PRO
0
140
ポーリング処理廃止によるイベント駆動アーキテクチャへの移行
seitarof
3
1.3k
Kubernetesでセルフホストが簡単なNewSQLを求めて / Seeking a NewSQL Database That's Simple to Self-Host on Kubernetes
nnaka2992
0
180
Reactive ❤️ Loom: A Forbidden Love Story
franz1981
2
160
コーディングルールの鮮度を保ちたい / keep-fresh-go-internal-conventions
handlename
0
230
仕様漏れ実装漏れをなくすトレーサビリティAI基盤のご紹介
orgachem
PRO
7
3.1k
生成 AI 時代のスナップショットテストってやつを見せてあげますよ(α版)
ojun9
0
300
GC言語のWasm化とComponent Modelサポートの実践と課題 - Scalaの場合
tanishiking
0
120
コードレビューをしない選択 #でぃーぷらすトウキョウ
kajitack
3
1.1k
Codexに役割を持たせる 他のAIエージェントと組み合わせる実務Tips
o8n
4
1.4k
Featured
See All Featured
The Director’s Chair: Orchestrating AI for Truly Effective Learning
tmiket
1
140
Designing for Timeless Needs
cassininazir
0
170
Put a Button on it: Removing Barriers to Going Fast.
kastner
60
4.2k
Color Theory Basics | Prateek | Gurzu
gurzu
0
260
Fashionably flexible responsive web design (full day workshop)
malarkey
408
66k
How STYLIGHT went responsive
nonsquared
100
6k
Leveraging LLMs for student feedback in introductory data science courses - posit::conf(2025)
minecr
1
210
The B2B funnel & how to create a winning content strategy
katarinadahlin
PRO
1
310
State of Search Keynote: SEO is Dead Long Live SEO
ryanjones
0
160
Optimizing for Happiness
mojombo
378
71k
How to Think Like a Performance Engineer
csswizardry
28
2.5k
What’s in a name? Adding method to the madness
productmarketing
PRO
24
4k
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