Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Can't you make it more like Bootstrap?

Can't you make it more like Bootstrap?

Slides from a talk I gave at June's MK Geek Night. This talk covers what the FT is doing to unify design across the FT and speed up development time.

Alice Bartlett

July 12, 2016
Tweet

More Decks by Alice Bartlett

Other Decks in Technology

Transcript

  1. Alice Bartlett
    Origami Lead, Financial Times
    @alicebartlett
    Can’t you make it more like
    Bootstrap?
    Considerations for building front end systems

    View Slide

  2. Hello

    View Slide

  3. I’m from the
    FINANCIAL TIMES

    View Slide

  4. I lead a project at the FT called
    Origami.
    @alicebartlett

    View Slide

  5. Origami is a 5 person team who
    develop frontend tools and
    services at the FT
    @alicebartlett

    View Slide

  6. The Origami team has 2 aims:
    1. Unify frontend styles across the FT
    2. Reduce time spent repeating work
    @alicebartlett

    View Slide

  7. Components,
    tools and
    services
    @alicebartlett

    View Slide

  8. There are lots of companies that
    have projects similar to Origami.
    @alicebartlett

    View Slide

  9. http://getbootstrap.com/

    View Slide

  10. https://www.lightningdesignsystem.com/

    View Slide

  11. https://rizzo.lonelyplanet.com/styleguide/design-elements/colours

    View Slide

  12. https://www.futurelearn.com/pattern-library

    View Slide

  13. Today I’m going to talk about
    Origami and some of these
    projects too
    @alicebartlett

    View Slide

  14. This is not a talk
    about design
    systems

    View Slide

  15. This is about what you build
    once you have your design
    system
    @alicebartlett

    View Slide

  16. THIS IS ABOUT
    SOFTWARE

    View Slide

  17. FIRST:
    FINANCIAL TIMES

    View Slide

  18. ft.com

    View Slide

  19. This is ft.com

    View Slide

  20. This design is
    known as
    “Falcon”

    View Slide

  21. ft.com

    View Slide

  22. aboutus.ft.com

    View Slide

  23. ftchinese.com

    View Slide

  24. The FT has a lot of other sites…
    @alicebartlett

    View Slide

  25. View Slide

  26. View Slide

  27. I don’t know how
    many frontend
    apps the FT has, it’s
    that many

    View Slide

  28. These designs currently share
    little or no code
    @alicebartlett

    View Slide

  29. Even though many of them have
    the same ui design
    @alicebartlett

    View Slide

  30. @alicebartlett
    shared design shared code

    View Slide

  31. @alicebartlett
    shared design & shared code

    View Slide

  32. @alicebartlett
    This is the close
    button for an
    overlay in the
    Falcon design

    View Slide

  33. button > span (CSS bg)
    a (x sign)
    a (CSS bg)
    a > img

    View Slide

  34. @alicebartlett
    There are four
    different
    versions of this
    live on FT.com.

    View Slide

  35. @alicebartlett
    Four different
    implementations
    of the same
    thing

    View Slide

  36. And those are things we can
    control the design for…
    @alicebartlett

    View Slide

  37. We have three
    different
    versions of
    the twitter
    logo on ft.com

    View Slide

  38. THE FT’S SITE IS
    CHANGING

    View Slide

  39. FT.com

    View Slide

  40. next.ft.com

    View Slide

  41. This is the opportunity for a
    generational shift in the way
    we build websites at the FT
    @alicebartlett

    View Slide

  42. The Origami team has 2 aims:
    1. Unify frontend styles across the FT
    2. Reduce time spent repeating work
    @alicebartlett

    View Slide

  43. DOWN WITH
    THIS SORT OF
    THING
    @alicebartlett

    View Slide

  44. WHAT’S IN A
    COMPONENT SYSTEM?

    View Slide

  45. 1. Components
    2. Tools
    3. Documentation
    @alicebartlett

    View Slide

  46. @alicebartlett
    Components

    View Slide

  47. @alicebartlett
    A component is some combination
    of CSS, HTML and JavaScript
    .css .html .js

    View Slide

  48. @alicebartlett
    .css .html .js

    View Slide

  49. @alicebartlett
    Components Application code Website
    .css .html .js
    .rb

    View Slide

  50. @alicebartlett
    Components Websites!
    Application code
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb

    View Slide

  51. Let’s have a look at an Origami
    specific example…
    @alicebartlett

    View Slide

  52. View Slide

  53. View Slide

  54. View Slide

  55. So that’s
    ads, header,
    icons, date,
    fonts, grid, tracking,
    colours, buttons

    View Slide

  56. There’s a lot of overlap
    between Origami, Lonely
    Planet’s Rizzo, or FutureLearn’s
    pattern library
    @alicebartlett

    View Slide

  57. @alicebartlett
    Tools
    Components

    View Slide

  58. @alicebartlett
    Components Websites!
    Application code
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb

    View Slide

  59. @alicebartlett
    Components Websites!
    Application code
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    QUITE HARD

    View Slide

  60. @alicebartlett
    Components Websites!
    Application code
    .rb
    .rb
    .rb
    .rb

    View Slide

  61. https://www.futurelearn.com/

    View Slide

  62. https://www.futurelearn.com/pattern-library

    View Slide

  63. @alicebartlett
    Components Websites!
    Application code
    .rb
    .rb
    .rb
    .rb

    View Slide

  64. @alicebartlett
    Components Websites!
    Application code
    .rb
    .rb
    .rb
    .rb

    View Slide

  65. @alicebartlett
    Website
    Components and
    Application code
    .rb
    .rb
    .rb
    .rb

    View Slide

  66. This is the simplest way to use
    an abstracted design system in
    your product.
    @alicebartlett

    View Slide

  67. The best tooling
    is no tooling*
    @alicebartlett

    View Slide

  68. @alicebartlett
    Components Websites!
    Application code
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb

    View Slide

  69. @alicebartlett
    Components Websites!
    Application code
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    QUITE HARD

    View Slide

  70. @alicebartlett
    Now
    tooling
    becomes
    important

    View Slide

  71. @alicebartlett
    Javascript
    CSS
    HTML

    View Slide

  72. @alicebartlett
    Components Websites!
    Application code
    Tools
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb

    View Slide

  73. If your sites are using the same
    languages…
    @alicebartlett

    View Slide

  74. Then you can just make your
    system work for that stack.
    @alicebartlett

    View Slide

  75. If your sites use
    ruby, then a gem is
    an excellent way to
    deal with this
    problem
    @alicebartlett

    View Slide

  76. @alicebartlett
    Components Websites!
    Application code
    Tools
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb

    View Slide

  77. http://rizzo.lonelyplanet.com/styleguide/

    View Slide

  78. $ gem install rizzo
    @alicebartlett
    Step 1:

    View Slide

  79. http://engineering.lonelyplanet.com/2014/05/18/a-maintainable-styleguide.html
    // Input
    = ui_component("forms/search", {
    label: “Search"
    })
    Step 2:

    View Slide

  80. @alicebartlett
    ✔ Javascript
    ✔ CSS
    ✔ HTML

    View Slide

  81. // Input
    = ui_component("forms/search", {
    label: “Search"
    })
    http://engineering.lonelyplanet.com/2014/05/18/a-maintainable-styleguide.html
    This is SO NEAT
    Step 2:

    View Slide

  82. This is also how GOV.UK’s
    component’s system works.
    (Inspired by Rizzo!)
    @alicebartlett

    View Slide

  83. @alicebartlett
    Components Websites!
    Application code
    Tools
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    BUT WAIT…

    View Slide

  84. @alicebartlett
    Components Websites!
    Application code
    Tools
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    WHAT IF YOUR CONSUMING
    APPLICATIONS AREN’T ALL
    IN THE SAME LANGUAGE

    View Slide

  85. @alicebartlett
    Components Websites!
    Application code
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    QUITE HARD

    View Slide

  86. Option 1: Tools for every
    language
    @alicebartlett

    View Slide

  87. @alicebartlett
    Components Websites!
    Application code
    Tools
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .py
    .rb
    .rb
    .rb
    .java

    View Slide

  88. Maintaining a toolset like this is
    a lot of work…
    @alicebartlett

    View Slide

  89. Option 2: Lose HTML delivery
    @alicebartlett

    View Slide

  90. @alicebartlett
    ✔ Javascript
    ✔ CSS
    ✘ HTML

    View Slide

  91. You can resolve the distribution
    of CSS and JS quite easily…
    @alicebartlett

    View Slide


  92. <br/>@alicebartlett<br/>

    View Slide

  93. Bower, npm
    @alicebartlett

    View Slide

  94. But templates…
    @alicebartlett

    View Slide

  95. There is no good way to let
    people include (customisable)
    templates in their projects
    @alicebartlett

    View Slide

  96. You have to tell users to copy
    and paste
    @alicebartlett

    View Slide

  97. This is a really bad idea…
    @alicebartlett

    View Slide

  98. People leave off or remove
    things they don’t understand,
    ARIA attributes, microformats
    @alicebartlett

    View Slide

  99. You can never change a class
    name again
    @alicebartlett

    View Slide

  100. You can’t automatically push
    out changes to components
    @alicebartlett

    View Slide

  101. You’re duplicating code
    @alicebartlett

    View Slide

  102. @alicebartlett
    Components Websites!
    Application code
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    .rb
    NO GOOD OPTIONS

    View Slide

  103. 1. Build and maintain a tool for
    every language
    2. Drop HTML distribution
    @alicebartlett

    View Slide

  104. A terrible
    choice

    View Slide

  105. Origami uses
    copy/paste

    View Slide

  106. @alicebartlett
    ✔ Javascript
    ✔ CSS
    ✘ HTML

    View Slide

  107. IF ONLY THERE WAS A
    SPEC OR SUITE OF
    SPECS THAT HANDLED
    DISTRIBUTION OF
    HTML…

    View Slide

  108. Yeah, we’re waiting
    for web components

    View Slide

  109. @alicebartlett
    ✔ Javascript
    ✔ CSS
    ✘ HTML

    View Slide

  110. The Origami Build Service
    @alicebartlett

    View Slide

  111. It’s basically a CDN
    @alicebartlett

    View Slide

  112. It’s basically a CDN
    OK it’s a bit cleverer than a CDN
    @alicebartlett

    View Slide

  113. @alicebartlett
    href="https://origami-build.ft.com/
    v2/bundles/css?modules=o-
    grid@^4.0.0,o-fonts@^1.4.0" />

    View Slide

  114. @alicebartlett
    href="https://origami-build.ft.com/
    v2/bundles/css?modules=o-
    grid@^4.0.0,o-fonts@^1.4.0" />

    View Slide

  115. @alicebartlett
    href="https://origami-build.ft.com/
    v2/bundles/css?modules=o-
    grid@^4.0.0,o-fonts@^1.4.0" />

    View Slide

  116. @alicebartlett
    href="https://origami-build.ft.com/
    v2/bundles/js?modules=o-
    grid@^4.0.0,o-fonts@^1.4.0" />

    View Slide

  117. The Build Service takes any
    combination of modules and
    returns their CSS and
    JavaScript
    @alicebartlett

    View Slide

  118. For CSS:
    - Concatenates module Sass
    - Runs an auto-prefixer across it
    - Compiles it
    - Minifies it
    - Returns it
    @alicebartlett

    View Slide

  119. For JS:
    - Concatenates all module JS
    - Babel
    - Minifies it
    - Returns it
    @alicebartlett

    View Slide

  120. People love this
    @alicebartlett

    View Slide

  121. 239,318,470
    Build Service requests for April 12 - May 12
    via Akamai

    View Slide

  122. But some people want more
    control
    @alicebartlett

    View Slide

  123. We took the code behind the
    Build Service, and made it an
    npm package called Origami
    Build Tools
    @alicebartlett

    View Slide

  124. FT.com has a release cycle of 3
    months, they use the Build
    Service
    @alicebartlett

    View Slide

  125. next.ft.com want a lot more
    control over their build process,
    they use Origami Build Tools
    @alicebartlett

    View Slide

  126. So we have these awesome tools
    that mean, no matter what your
    release cycle is, or your tech
    stack, you can use Origami
    @alicebartlett

    View Slide

  127. But that’s not enough.
    @alicebartlett

    View Slide

  128. @alicebartlett
    Docs
    Tools
    Components

    View Slide

  129. FREE MARKET
    SOFTWARE
    TEAMS

    View Slide

  130. … teams are allowed and
    encouraged to pick the best value
    tools for the job at hand, be they
    things developed and supported
    by internal teams or external to
    the company.
    Matt Chadburn,
    Principal Developer
    http://matt.chadburn.co.uk/notes/teams-as-services.html

    View Slide

  131. So Origami is competing with
    any other tool, or the option to
    not use Origami at all.
    @alicebartlett

    View Slide

  132. This keeps us pretty focussed
    @alicebartlett

    View Slide

  133. When I joined the FT in October,
    I did some user research on
    Origami
    @alicebartlett

    View Slide

  134. I interviewed people around the
    business, developers, designers
    and journalists, product
    managers
    @alicebartlett

    View Slide

  135. And what people told me was
    mostly positive.
    @alicebartlett

    View Slide

  136. But I did discover one problem.
    Our documentation was
    confusing people or boring
    them
    @alicebartlett

    View Slide

  137. http://origami.ft.com

    View Slide

  138. http://registry.origami.ft.com

    View Slide

  139. http://github.com/financial-times/o-gallery

    View Slide

  140. HOW THE F**K AM I
    SUPPOSED TO FIND
    TIME TO READ ALL
    OF THIS STUFF?
    an anonymous Origami user

    View Slide

  141. I wish this was just
    more like bootstrap’s
    documentation
    an anonymous Origami user

    View Slide

  142. http://getbootstrap.com/getting-started/

    View Slide

  143. Using Origami is as easy as
    pasting a tag into your

    @alicebartlett

    View Slide

  144. It’s as easy as Bootstrap
    @alicebartlett

    View Slide

  145. https://www.polymer-project.org/1.0/

    View Slide

  146. We re-wrote our documentation
    using the principles used to
    write Django’s docs
    @alicebartlett

    View Slide

  147. https://jacobian.org/writing/great-documentation/

    View Slide

  148. We have a documentation style
    guide, just like we have guides
    for JavaScript and Sass
    @alicebartlett

    View Slide

  149. https://github.com/financial-times/ft-origami

    View Slide

  150. Along the same track as
    documentation, you’ll find
    marketing.
    @alicebartlett

    View Slide

  151. Marketing is how you convince
    people to use your stuff without
    them having to think too hard
    about it
    @alicebartlett

    View Slide

  152. The amount of marketing you
    have to do should scale with the
    number of users you have (or
    want)
    @alicebartlett

    View Slide

  153. http://getbootstrap.com/

    View Slide

  154. https://www.lightningdesignsystem.com/

    View Slide

  155. https://www.futurelearn.com/pattern-library

    View Slide

  156. Marketing isn’t just pretty
    websites
    @alicebartlett

    View Slide

  157. And at a certain scale, you’ll
    need a communications plan for
    new releases.
    @alicebartlett

    View Slide

  158. You should publish your
    incident reports
    @alicebartlett

    View Slide

  159. With free market software
    teams, this matters
    @alicebartlett

    View Slide

  160. Documentation
    isn’t complicated.
    It’s just hard.

    View Slide

  161. People won’t fight
    you, they’ll just
    ignore you

    View Slide

  162. Conclusion:
    1. Components at the centre
    2. Make the simplest tool for the
    job (maybe no tools at all!)
    3. Care for your documentation
    @alicebartlett

    View Slide

  163. Alice Bartlett
    Origami Lead, Financial Times
    @alicebartlett
    Thanks

    View Slide