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
Introduction to Spree (A Ruby on Rails E-Commer...
Search
Sponsored
·
Ship Features Fearlessly
Turn features on and off without deploys. Used by thousands of Ruby developers.
→
gmacdougall
February 26, 2014
Programming
0
210
Introduction to Spree (A Ruby on Rails E-Commerce App)
Presented at ConFoo 2014.
gmacdougall
February 26, 2014
Tweet
Share
More Decks by gmacdougall
See All by gmacdougall
Practical Code Review with Gerrit
gmacdougall
0
86
Other Decks in Programming
See All in Programming
副作用をどこに置くか問題:オブジェクト指向で整理する設計判断ツリー
koxya
1
610
QAフローを最適化し、品質水準を満たしながらリリースまでの期間を最短化する #RSGT2026
shibayu36
2
4.4k
Data-Centric Kaggle
isax1015
2
780
Smart Handoff/Pickup ガイド - Claude Code セッション管理
yukiigarashi
0
140
24時間止められないシステムを守る-医療ITにおけるランサムウェア対策の実際
koukimiura
1
110
AIエージェント、”どう作るか”で差は出るか? / AI Agents: Does the "How" Make a Difference?
rkaga
4
2k
AI & Enginnering
codelynx
0
110
要求定義・仕様記述・設計・検証の手引き - 理論から学ぶ明確で統一された成果物定義
orgachem
PRO
1
160
Oxlintはいいぞ
yug1224
5
1.3k
Apache Iceberg V3 and migration to V3
tomtanaka
0
160
それ、本当に安全? ファイルアップロードで見落としがちなセキュリティリスクと対策
penpeen
7
3.9k
なるべく楽してバックエンドに型をつけたい!(楽とは言ってない)
hibiki_cube
0
140
Featured
See All Featured
Discover your Explorer Soul
emna__ayadi
2
1.1k
Responsive Adventures: Dirty Tricks From The Dark Corners of Front-End
smashingmag
254
22k
ラッコキーワード サービス紹介資料
rakko
1
2.3M
技術選定の審美眼(2025年版) / Understanding the Spiral of Technologies 2025 edition
twada
PRO
117
110k
Art, The Web, and Tiny UX
lynnandtonic
304
21k
AI Search: Implications for SEO and How to Move Forward - #ShenzhenSEOConference
aleyda
1
1.1k
SEO for Brand Visibility & Recognition
aleyda
0
4.2k
Large-scale JavaScript Application Architecture
addyosmani
515
110k
Designing for Performance
lara
610
70k
How People are Using Generative and Agentic AI to Supercharge Their Products, Projects, Services and Value Streams Today
helenjbeal
1
130
HDC tutorial
michielstock
1
390
Agile Leadership in an Agile Organization
kimpetersen
PRO
0
83
Transcript
Introduction to Spree A Ruby on Rails E-Commerce App by
Gregor MacDougall Twitter: @GrMacDougall Website: http://www.freerunningtech.com/
About Me Gregor MacDougall Sr. Software Developer @ FreeRunning Technologies
None
The Grand Tour rake sandbox
None
None
None
None
None
None
None
None
None
Look Familiar? • Competitors ◦ Marketplace Solutions ◦ SaaS Solutions
◦ Self-hosted Solutions ▪ Magento, VirtueMart, ZenCart, Prestashop, osCommerce, OpenCart, …
What Makes Spree Different? • Ruby on Rails • Rails
Engine • mount Spree::Core::Engine, :at => '/store' ◦ / -> Your App ◦ /store -> Spree ◦ /blog -> Something Else
How Does Spree Model Data? Product • Basic Product ◦
Name ◦ Description ◦ SKU ◦ Weight, Dimensions ◦ Price
How Does Spree Model Data? Product • Name • Description
Variant • SKU • Weight, Dimensions • Price
How Does Spree Model Data? Product - OptionType: colour Variant
- OptionValue: black Product - OptionType: colour Variant - OptionValue: red
None
How Does Spree Model Data?
None
None
None
Customizing Spree • View Customization ◦ CSS ◦ Replacing Templates
◦ Deface • Logic Customization ◦ Adding new logic ◦ Changing existing logic
xray-rails
Replacing a view Create the following file: ./app/views/spree/shared/_search.html.erb
Using Deface to Modify Templates
Deface app/views/spree/shared/_products.html.erb
Deface app/overrides/before_products.rb
Deface (Matching on Template)
Customizability Ruby Meta-Programming (pry examples)
With Great Power...
Mixed Nuts Store
Create The Nut Model rails g model Spree::Nut name:string
Create The Nut Variant Association rails g model Spree::VariantNut variant:
references nut:references
Our Models
Nut Model In Action
Modifying Spree’s Classes app/models/spree/variant_decorator.rb
Overriding Spree Functionality
Other Spree Features • Promotions & Discounts • API •
Stock Location & Inventory Tracking • ActiveMerchant Support (100+ Payment Gateways) • Full i18n support (~40 languages currently supported) • Large Library of Extensions • and much more
For More Information Spree http://www.spreecommerce.com/ http://www.github.com/spree/spree FreeRunning Technologies http://www.freerunningtech.com/
About Me Twitter: @GrMacDougall Github: https://github.com/gmacdougall E-mail:
[email protected]
Slides: http://www.freerunningtech.com/confoo
More From Me! Practical Code Review with Gerrit 9:00 AM Tomorrow (Same Room)