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
Shared Templates for Rails 3
Search
Sponsored
·
Ship Features Fearlessly
Turn features on and off without deploys. Used by thousands of Ruby developers.
→
Alexey
October 01, 2012
Programming
190
1
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
Shared Templates for Rails 3
Shared Templates for Rails 3
Alexey
October 01, 2012
Other Decks in Programming
See All in Programming
이 함수, 실패하면 어떻게 되나요? null부터 Rich Errors까지, Kotlin 에러 처리 15년
haeti2
0
120
XP祭りでしか伝わらないフリップネタ #xpjug
murabayashi
0
100
承認済みなのに差戻しできてしまうバグ、型で潰せます
shinchit
0
130
業務時間外もAIに働いてもらう話
colorful12
3
9.9k
まずはプロンプトガイドを読もう、話はそれからだ
kiakiraki
1
250
GKE アップグレード前に知っておきたい Blue/Green と PDB の関係
stkk
0
140
PyConJP2026_wat_Python × Signal Processing: How to Draw Pictures with Sound Using Spectrogram Art
wat
0
650
Can LLMs Replicate 4 Years of Compose Migration? Exploring the boundaries of automation with 279 XML files from a real product
makun
0
130
【DroidKaigi 2026】「アクセシビリティを利用するとき、 アクセシビリティもまたこちらを利用している」 〜マルウェアによる攻撃と防衛について〜
halunoyo
0
300
Gmail/Google DriveをトリガーにAIエージェントを動かそう! / Run AI agents with Gmail/Google Drive as triggers!
har1101
3
460
信頼性の目標を誰も求めてない
shubox
0
480
Jindong: Introducing Declarative Haptics in Compose Multiplatform
l2hyunwoo
0
140
Featured
See All Featured
Designing Experiences People Love
moore
143
24k
The untapped power of vector embeddings
frankvandijk
2
1.9k
Imperfection Machines: The Place of Print at Facebook
scottboms
270
14k
Marketing Yourself as an Engineer | Alaka | Gurzu
gurzu
0
290
The MySQL Ecosystem @ GitHub 2015
samlambert
251
13k
Cheating the UX When There Is Nothing More to Optimize - PixelPioneers
stephaniewalter
287
14k
Digital Ethics as a Driver of Design Innovation
axbom
PRO
1
410
Rails Girls Zürich Keynote
gr2m
96
14k
Designing for Performance
lara
611
70k
GitHub's CSS Performance
jonrohan
1033
470k
RailsConf & Balkan Ruby 2019: The Past, Present, and Future of Rails at GitHub
eileencodes
141
35k
The B2B funnel & how to create a winning content strategy
katarinadahlin
PRO
1
500
Transcript
Shared Templates for Rails 3 EuRuKo 2012 Amsterdam Alexey Vasiliev
Railsware
Hello my name is Alexey Vasiliev (le0pard) @leopard_me https://github.com/le0pard Engineer
at Railsware.com
Ways to render web interface • Rails render content on
backend and send it to browser • Rails backend have only REST API and interface rendered by JavaScript in web application
Hybrid web application • Interface part rendered on backend and
part rendered on frontend • Very often need to use the same templates for backend and frontend • We need DRY!
And we love Mustache!
smt_rails • smt_rails (Shared Mustache Templates for Rails 3) •
gem 'smt_rails' • rails g smt_rails:install • You're done!
Example Template: Hello {{msg}}!!! ActionView: <%= render "tests/test", :mustache =>
{msg: "Test"} %> JavaScript: var content = SMT['tests/test']({msg: "Test"});
sht_rails • sht_rails (Shared Handlebars Templates for Rails 3) •
Build for people who like handlebars.js :)
Example http://smt.rw.rw/
Questions? Ideas? Opinions?