Confoo

Nicholas Simmons
Nicholas SimmonsServer Programmer en Electronic Arts
To a Single Page Web
App…
and Back Again
Nick Simmons
Confoo
Montreal 2015
ABOUT ME
STAR WARS IN ASIA
Confoo
Confoo
SHOPIFY ADMIN EVOLUTION
Admin Classic: + ERB +
Admin 2:
Admin Next: ...
SHOPIFY - MAY 2013
+ =
BUT...
“Batman is hard!” - said everyone.
LEARNING BATMAN
Superhero
Newb
Time
Read Admin code
Read Batman docs
Back to Admin code
Ask for help
Read Batman code
HACK DAYS - JUNE 2013
“Let’s use Batman for our project!”
“Where do I start?”
“HELP!”
“F**k this, I’m using Rails”
HARSH REALITY
Complexity does not scale well.
NEW FEATURES - JUL TO NOV 2013
“Where should I put this code?”
“I’m a frontend dev, client has all the
state that I need.”
“Let’s do it client side!”
THE RISE OF MOBILE APPS
JSON API
BUSINESS LOGIC BUSINESS LOGIC
CHOOSING THE RIGHT PATH
Doing something because it’s possible
doesn’t make it the right choice.
BATMAN DEEP DIVE - DEC 2013
“The Admin is looking a little janky.”
Confoo
ORDER PAGE BINDINGS
THE COST OF BATMAN
ADMIN REBOOT
WHAT IS ADMIN-NEXT?
Turbograft Twine+ +
https://github.com/Shopify/twinehttps://github.com/Shopify/turbograft
PARTIAL PAGE REPLACEMENT
PARTIAL PAGE REPLACEMENT
UPDATE AND REFRESH
UPDATE AND REFRESH
LESSONS LEARNED
If you only remember these 4 points from my
talk, that’s cool with me.
WHEN CHOOSING YOUR TECH
Focus on what your needs are right now.
WHEN CHOOSING YOUR TECH
Consider your team’s strengths.
WHEN CHOOSING YOUR TECH
A simple approach scales better than a
complex one.
WHEN VALIDATING YOUR TECH
Vet your choice by building the most
complicated part first.
How are we doing?
ADMIN-NEXT + 6 MONTHS
Thanks!
1 de 31

Recomendados

New Age Marketing - By Kazim Ali Khan por
New Age Marketing - By Kazim Ali KhanNew Age Marketing - By Kazim Ali Khan
New Age Marketing - By Kazim Ali Khan Kazim Ali Khan
403 vistas2 diapositivas
A SUSTAINABLE WEB FRONTEND por
A SUSTAINABLE WEB FRONTENDA SUSTAINABLE WEB FRONTEND
A SUSTAINABLE WEB FRONTENDSogoOhta
818 vistas64 diapositivas
гзин por
гзингзин
гзинBatchimeg Tomorbaatar
930 vistas12 diapositivas
зараг үзйн их тэлэн por
зараг үзйн их тэлэнзараг үзйн их тэлэн
зараг үзйн их тэлэнtuya_od
638 vistas2 diapositivas
L 2 gazarzuin ih neelt por
L 2 gazarzuin ih neeltL 2 gazarzuin ih neelt
L 2 gazarzuin ih neeltBMunguntuul
7.4K vistas28 diapositivas
Түүх : Колони por
Түүх : КолониТүүх : Колони
Түүх : КолониHobbit Nawaka
6.2K vistas21 diapositivas

Más contenido relacionado

Último

Bootstrapping vs Venture Capital.pptx por
Bootstrapping vs Venture Capital.pptxBootstrapping vs Venture Capital.pptx
Bootstrapping vs Venture Capital.pptxZeljko Svedic
15 vistas17 diapositivas
Ports-and-Adapters Architecture for Embedded HMI por
Ports-and-Adapters Architecture for Embedded HMIPorts-and-Adapters Architecture for Embedded HMI
Ports-and-Adapters Architecture for Embedded HMIBurkhard Stubert
33 vistas19 diapositivas
Unlocking the Power of AI in Product Management - A Comprehensive Guide for P... por
Unlocking the Power of AI in Product Management - A Comprehensive Guide for P...Unlocking the Power of AI in Product Management - A Comprehensive Guide for P...
Unlocking the Power of AI in Product Management - A Comprehensive Guide for P...NimaTorabi2
16 vistas17 diapositivas
Introduction to Gradle por
Introduction to GradleIntroduction to Gradle
Introduction to GradleJohn Valentino
6 vistas7 diapositivas
Transport Management System - Shipment & Container Tracking por
Transport Management System - Shipment & Container TrackingTransport Management System - Shipment & Container Tracking
Transport Management System - Shipment & Container TrackingFreightoscope
5 vistas3 diapositivas
Electronic AWB - Electronic Air Waybill por
Electronic AWB - Electronic Air Waybill Electronic AWB - Electronic Air Waybill
Electronic AWB - Electronic Air Waybill Freightoscope
5 vistas1 diapositiva

Último(20)

Bootstrapping vs Venture Capital.pptx por Zeljko Svedic
Bootstrapping vs Venture Capital.pptxBootstrapping vs Venture Capital.pptx
Bootstrapping vs Venture Capital.pptx
Zeljko Svedic15 vistas
Ports-and-Adapters Architecture for Embedded HMI por Burkhard Stubert
Ports-and-Adapters Architecture for Embedded HMIPorts-and-Adapters Architecture for Embedded HMI
Ports-and-Adapters Architecture for Embedded HMI
Burkhard Stubert33 vistas
Unlocking the Power of AI in Product Management - A Comprehensive Guide for P... por NimaTorabi2
Unlocking the Power of AI in Product Management - A Comprehensive Guide for P...Unlocking the Power of AI in Product Management - A Comprehensive Guide for P...
Unlocking the Power of AI in Product Management - A Comprehensive Guide for P...
NimaTorabi216 vistas
Transport Management System - Shipment & Container Tracking por Freightoscope
Transport Management System - Shipment & Container TrackingTransport Management System - Shipment & Container Tracking
Transport Management System - Shipment & Container Tracking
Freightoscope 5 vistas
Electronic AWB - Electronic Air Waybill por Freightoscope
Electronic AWB - Electronic Air Waybill Electronic AWB - Electronic Air Waybill
Electronic AWB - Electronic Air Waybill
Freightoscope 5 vistas
Dev-HRE-Ops - Addressing the _Last Mile DevOps Challenge_ in Highly Regulated... por TomHalpin9
Dev-HRE-Ops - Addressing the _Last Mile DevOps Challenge_ in Highly Regulated...Dev-HRE-Ops - Addressing the _Last Mile DevOps Challenge_ in Highly Regulated...
Dev-HRE-Ops - Addressing the _Last Mile DevOps Challenge_ in Highly Regulated...
TomHalpin96 vistas
Automated Testing of Microsoft Power BI Reports por RTTS
Automated Testing of Microsoft Power BI ReportsAutomated Testing of Microsoft Power BI Reports
Automated Testing of Microsoft Power BI Reports
RTTS10 vistas
Understanding HTML terminology por artembondar5
Understanding HTML terminologyUnderstanding HTML terminology
Understanding HTML terminology
artembondar57 vistas
Top-5-production-devconMunich-2023.pptx por Tier1 app
Top-5-production-devconMunich-2023.pptxTop-5-production-devconMunich-2023.pptx
Top-5-production-devconMunich-2023.pptx
Tier1 app9 vistas
predicting-m3-devopsconMunich-2023-v2.pptx por Tier1 app
predicting-m3-devopsconMunich-2023-v2.pptxpredicting-m3-devopsconMunich-2023-v2.pptx
predicting-m3-devopsconMunich-2023-v2.pptx
Tier1 app12 vistas
How Workforce Management Software Empowers SMEs | TraQSuite por TraQSuite
How Workforce Management Software Empowers SMEs | TraQSuiteHow Workforce Management Software Empowers SMEs | TraQSuite
How Workforce Management Software Empowers SMEs | TraQSuite
TraQSuite6 vistas
360 graden fabriek por info33492
360 graden fabriek360 graden fabriek
360 graden fabriek
info33492165 vistas
JioEngage_Presentation.pptx por admin125455
JioEngage_Presentation.pptxJioEngage_Presentation.pptx
JioEngage_Presentation.pptx
admin1254558 vistas

Destacado

Getting into the tech field. what next por
Getting into the tech field. what next Getting into the tech field. what next
Getting into the tech field. what next Tessa Mero
6.6K vistas22 diapositivas
Google's Just Not That Into You: Understanding Core Updates & Search Intent por
Google's Just Not That Into You: Understanding Core Updates & Search IntentGoogle's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search IntentLily Ray
6.9K vistas99 diapositivas
How to have difficult conversations por
How to have difficult conversations How to have difficult conversations
How to have difficult conversations Rajiv Jayarajah, MAppComm, ACC
5.6K vistas19 diapositivas
Introduction to Data Science por
Introduction to Data ScienceIntroduction to Data Science
Introduction to Data ScienceChristy Abraham Joy
82.6K vistas51 diapositivas
Time Management & Productivity - Best Practices por
Time Management & Productivity -  Best PracticesTime Management & Productivity -  Best Practices
Time Management & Productivity - Best PracticesVit Horky
169.8K vistas42 diapositivas
The six step guide to practical project management por
The six step guide to practical project managementThe six step guide to practical project management
The six step guide to practical project managementMindGenius
36.7K vistas27 diapositivas

Destacado(20)

Getting into the tech field. what next por Tessa Mero
Getting into the tech field. what next Getting into the tech field. what next
Getting into the tech field. what next
Tessa Mero6.6K vistas
Google's Just Not That Into You: Understanding Core Updates & Search Intent por Lily Ray
Google's Just Not That Into You: Understanding Core Updates & Search IntentGoogle's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search Intent
Lily Ray6.9K vistas
Time Management & Productivity - Best Practices por Vit Horky
Time Management & Productivity -  Best PracticesTime Management & Productivity -  Best Practices
Time Management & Productivity - Best Practices
Vit Horky169.8K vistas
The six step guide to practical project management por MindGenius
The six step guide to practical project managementThe six step guide to practical project management
The six step guide to practical project management
MindGenius36.7K vistas
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright... por RachelPearson36
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
RachelPearson3612.7K vistas
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present... por Applitools
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
Applitools55.5K vistas
12 Ways to Increase Your Influence at Work por GetSmarter
12 Ways to Increase Your Influence at Work12 Ways to Increase Your Influence at Work
12 Ways to Increase Your Influence at Work
GetSmarter401.7K vistas
Ride the Storm: Navigating Through Unstable Periods / Katerina Rudko (Belka G... por DevGAMM Conference
Ride the Storm: Navigating Through Unstable Periods / Katerina Rudko (Belka G...Ride the Storm: Navigating Through Unstable Periods / Katerina Rudko (Belka G...
Ride the Storm: Navigating Through Unstable Periods / Katerina Rudko (Belka G...
DevGAMM Conference3.6K vistas
Barbie - Brand Strategy Presentation por Erica Santiago
Barbie - Brand Strategy PresentationBarbie - Brand Strategy Presentation
Barbie - Brand Strategy Presentation
Erica Santiago25.1K vistas
Good Stuff Happens in 1:1 Meetings: Why you need them and how to do them well por Saba Software
Good Stuff Happens in 1:1 Meetings: Why you need them and how to do them wellGood Stuff Happens in 1:1 Meetings: Why you need them and how to do them well
Good Stuff Happens in 1:1 Meetings: Why you need them and how to do them well
Saba Software25.3K vistas
Introduction to C Programming Language por Simplilearn
Introduction to C Programming LanguageIntroduction to C Programming Language
Introduction to C Programming Language
Simplilearn8.5K vistas
The Pixar Way: 37 Quotes on Developing and Maintaining a Creative Company (fr... por Palo Alto Software
The Pixar Way: 37 Quotes on Developing and Maintaining a Creative Company (fr...The Pixar Way: 37 Quotes on Developing and Maintaining a Creative Company (fr...
The Pixar Way: 37 Quotes on Developing and Maintaining a Creative Company (fr...
Palo Alto Software88.4K vistas
9 Tips for a Work-free Vacation por Weekdone.com
9 Tips for a Work-free Vacation9 Tips for a Work-free Vacation
9 Tips for a Work-free Vacation
Weekdone.com7.2K vistas
I Rock Therefore I Am. 20 Legendary Quotes from Prince por Empowered Presentations
I Rock Therefore I Am. 20 Legendary Quotes from PrinceI Rock Therefore I Am. 20 Legendary Quotes from Prince
I Rock Therefore I Am. 20 Legendary Quotes from Prince
Empowered Presentations142.9K vistas
How to Map Your Future por SlideShop.com
How to Map Your FutureHow to Map Your Future
How to Map Your Future
SlideShop.com275.1K vistas
Beyond Pride: Making Digital Marketing & SEO Authentically LGBTQ+ Inclusive -... por AccuraCast
Beyond Pride: Making Digital Marketing & SEO Authentically LGBTQ+ Inclusive -...Beyond Pride: Making Digital Marketing & SEO Authentically LGBTQ+ Inclusive -...
Beyond Pride: Making Digital Marketing & SEO Authentically LGBTQ+ Inclusive -...
AccuraCast3.4K vistas

Confoo

Notas del editor

  1. Nick Simmons from Shopify. Dev lead for Admin team. This talk is about my experience building the Shopify Admin.
  2. Montreal is my city. I was not born here, but my father was. Studied at Concordia and worked here for many years. Habs are my team.
  3. - Worked for LucasArts in Singapore. - Backend developer for online games. - Interest in JS MVC and single page web app began. - Disney bought Lucas, not interested in games. - That was the end of Lucas, and my time in Singapore.
  4. - Moved back to Canada. - Been at Shopify for almost 2 years. - Joined the Admin team.
  5. - I joined the Admin team. - Interface for shop owners. - Large web app: lots of pages, lots of forms, lots of data.
  6. - Classic: RoR app, view templates, jQuery sprinkled around. - Project began to convert Admin into single page app. - Decision to build their own framework. - Batman + Admin2 was the end result of this. Released July 2013. - 6 months later we decided to to move away from Batman. - Spent the next 8 months building AdminNext.
  7. - Batman was in polish stage. - Admin 2 was wrapping up, shipping soon. - Everyone was pretty excited about our JS MVC app. - No more full page reloads on page transitions. - All of our HTML endpoints were replaced by JSON API. - Server doesn’t care about UI any more. - Now Admin is just another API client!
  8. - Loved JS MVC and single page web app concept. - Batman really hard to learn. - At first I thought it was just me.
  9. - Read Admin code: So much going on, hard to figure out how everything ties together. - Read Batman docs: Gives a decent overview, but not enough simple examples to explain patterns. - Back to Admin code: Discovery of undocumented Batman features. - Ask for help: Not enough Batman experts to help the rapidly growing team. - Read Batman code: Time consuming effort to wrap your head around how everything works.
  10. - A lot of people wanted to try out Batman for their own projects - Went through same struggles as I did
  11. - Batman was a big framework with a lot of moving parts under the hood. - Intuition alone was not enough to grasp Batman. - A lack of documentation with solid examples made it really hard for people to jump in. - Many concepts and patterns spread through tribal knowledge. - Experts and tribal knowledge does not scale well.
  12. - Most of Admin team new to Rails. - Spend most of our time in client: Coffeescript. - Batman opens door for more client side business logic. - Admin team’s comfort zone, so we put more code into client.
  13. - POS also in development. - They are iOS developers, and most comfortable in their environment. - Same problems solved again. - Duplicated, complex business rules that should have been part of API. - Many bugs result from subtle differences between our client logic.
  14. We were relying on what the framework offered us too much instead of questioning whether it was really the best choice. We did not reflect on our decisions at key points in time. When additional clients became a reality we should have considered moving more logic back to the server. Another great historical example: SOAP
  15. - Page loads were visibly slow to finish rendering. - Expectation was page loads would be fast, but were seeing opposite.
  16. - This example shows how order show page should load vs. how it loads it batman. - Notice section towards the bottom fills in gradually after page load has completed? - Due to how our binding system works.
  17. - A lot of bindings on this page! - But when do any of these bindings get updated? - All require roundtrip to server, updated based on server response. - This works, but is not giving us that much. - Turns out, most of our Admin pages are like this.
  18. - Every time you visit Admin, Batman and Admin2 (with all html templates for all files) must be downloaded. - Caching does help, but deploy so often that cache is busted several times a day. - On slower connections it makes experience less than ideal. - Is upfront cost worth benefits? - Add increased memory footprint due to additional client side state.
  19. - Decision was made to prototype some alternative solutions to Batman. - Keep what worked, throw away what didn’t.
  20. - For most part, it’s just Rails. Most of our product devs are very familiar with it. - Allows us to specify which nodes in DOM we want to replace. Avoids full page reloads! - We still use API endpoints, but now they return HTML for Admin. Server does most of the rendering logic. - Let server do the work (we’re good at scaling server!) - Our binding system is currently 500 lines of javascript.
  21. - Admin has been running 100% on AdminNext tech for almost 6 months. - Everyone is doing Admin work now - Admin team scope has completely changed. - People are able to jump in and figure things out quickly. - Client side logic has been reduced to UI details. - Vast majority of bindings have been converted to ERB. - Even after building some of our most complicated views, amount of code added is very small. - Ongoing challenge of keeping our approach simple while supporting new problems that are not currently supported. - Overall very satisfied with our decision.