Slide 1

Slide 1 text

O que o Front end pode aprender com o Rails

Slide 2

Slide 2 text

@lucasmazza

Slide 3

Slide 3 text

http:/ /www.casadocodigo.com.br/products/livro-html-css

Slide 4

Slide 4 text

No content

Slide 5

Slide 5 text

No content

Slide 6

Slide 6 text

No content

Slide 7

Slide 7 text

No content

Slide 8

Slide 8 text

Partials Rails Assets Bourbon CoffeScript Asset Pipeline Ember Sass Compass Haml Helpers Rake Variants ✗

Slide 9

Slide 9 text

No content

Slide 10

Slide 10 text

No content

Slide 11

Slide 11 text

Comunalidade 1

Slide 12

Slide 12 text

“We confess the fact that we are not as special as we like to believe.” DHH @ RailsConf 2008

Slide 13

Slide 13 text

No content

Slide 14

Slide 14 text

No content

Slide 15

Slide 15 text

Problemas comuns & Soluções comuns

Slide 16

Slide 16 text

Convention over Configuration

Slide 17

Slide 17 text

Defaults over Choices

Slide 18

Slide 18 text

Paradox of Choice “People like choices a lot better than actually having to choose.” DHH @ RailsConf 2008

Slide 19

Slide 19 text

Barry Schwartz - The paradox of choice http:/ /www.ted.com/talks/barry_schwartz_on_the_paradox_of_choice

Slide 20

Slide 20 text

Remover escolhas triviais

Slide 21

Slide 21 text

“We want to have as much time as we can for the challenging tasks” Yehuda Katz @ RailsConf 2014

Slide 22

Slide 22 text

10 Years! - Yehuda Katz https:/ /www.youtube.com/watch?v=9naDS3r4MbY

Slide 23

Slide 23 text

No content

Slide 24

Slide 24 text

• Package Manager?

Slide 25

Slide 25 text

• Package Manager? • Module Loader?

Slide 26

Slide 26 text

• Package Manager? • Module Loader? • MVC Framework?

Slide 27

Slide 27 text

• Package Manager? • Module Loader? • MVC Framework? • Test Framework?

Slide 28

Slide 28 text

• Package Manager? • Module Loader? • MVC Framework? • Test Framework? • Task Runner?

Slide 29

Slide 29 text

• Package Manager? • Module Loader? • MVC Framework? • Test Framework? • Task Runner? • CSS Architecture?

Slide 30

Slide 30 text

• Package Manager? • Module Loader? • MVC Framework? • Test Framework? • Task Runner? • CSS Architecture? • …

Slide 31

Slide 31 text

• Package Manager? • Module Loader? • MVC Framework? • Test Framework? • Task Runner? • CSS Architecture? • … ??

Slide 32

Slide 32 text

No content

Slide 33

Slide 33 text

2 Open Source

Slide 34

Slide 34 text

No content

Slide 35

Slide 35 text

Soluções compartilhadas para problemas comuns

Slide 36

Slide 36 text

Open Source Seu código Webapp XYZ

Slide 37

Slide 37 text

No content

Slide 38

Slide 38 text

Open Source Seu código Snowflake CO.

Slide 39

Slide 39 text

No content

Slide 40

Slide 40 text

npm bower ender volo component jam duo spm jspm … ಠ_ಠ

Slide 41

Slide 41 text

No content

Slide 42

Slide 42 text

“I find it frustrating and hypocritical to hear, “This is a great time to get involved for people who are interested in helping to shape this project…” from people who chose not to get involved–rather, choosing to do something on their own.“ Patrick Masson - Joiners, Not Starters http:/ /pmasson.wordpress.com/2013/10/16/joiners-not-starters/

Slide 43

Slide 43 text

“[…]my point is simply, before starting a new open source project, please look for one to join.” Patrick Masson - Joiners, Not Starters http:/ /pmasson.wordpress.com/2013/10/16/joiners-not-starters/

Slide 44

Slide 44 text

Disrupção e fragmentação precisam convergir em algum momento

Slide 45

Slide 45 text

• Rails & Merb

Slide 46

Slide 46 text

• Rails & Merb • rvm vs rbenv vs chruby

Slide 47

Slide 47 text

• Rails & Merb • rvm vs rbenv vs chruby • RubySpec

Slide 48

Slide 48 text

(não é que novos projetos não são bem vindos…)

Slide 49

Slide 49 text

Open Source não é só código

Slide 50

Slide 50 text

• Bug reports & troubleshooting

Slide 51

Slide 51 text

• Bug reports & troubleshooting • Documentação

Slide 52

Slide 52 text

• Bug reports & troubleshooting • Documentação • Tutoriais, exemplos e wikis

Slide 53

Slide 53 text

• Bug reports & troubleshooting • Documentação • Tutoriais, exemplos e wikis • Mailing Lists & Stack Overflow

Slide 54

Slide 54 text

“Don't feel guilty about not contributing to open source" Julia Evans http:/ /jvns.ca/blog/2014/04/26/i-dont-feel-guilty-about-not-contributing-to-open-source/

Slide 55

Slide 55 text

3 Abstrações & Frameworks

Slide 56

Slide 56 text

“f**k jQuery, Zepto or any others javascript frameworks!” Todo mundo, em algum momento

Slide 57

Slide 57 text

❤ jQuery ❤

Slide 58

Slide 58 text

No content

Slide 59

Slide 59 text

DOM jQuery seu código

Slide 60

Slide 60 text

DOM jQuery seu código browser, webserver, OSs,…

Slide 61

Slide 61 text

DOM jQuery seu código Promises

Slide 62

Slide 62 text

❤ Promises/A+ ❤

Slide 63

Slide 63 text

DOM jQuery seu código Promises Service Workers

Slide 64

Slide 64 text

DOM jQuery seu código Promises Generators

Slide 65

Slide 65 text

DOM jQuery seu código Promises …

Slide 66

Slide 66 text

DOM jQuery seu código Promises … …

Slide 67

Slide 67 text

DOM jQuery Promises … … …

Slide 68

Slide 68 text

“It's our job as modern programmers not to abandon abstractions due to these deficiencies, but to embrace the useful elements of them, to adapt the working parts and construct ever so slightly less leaky and broken abstractions over time. “ Jeff Atwood - All Abstractions Are Failed Abstractions http:/ /blog.codinghorror.com/all-abstractions-are-failed-abstractions/

Slide 69

Slide 69 text

Does this make our code at least a little easier: • to write? • To understand? • To troubleshoot? • Are we better off with this than we were without it? Jeff Atwood - All Abstractions Are Failed Abstractions http:/ /blog.codinghorror.com/all-abstractions-are-failed-abstractions/

Slide 70

Slide 70 text

“When you decide to not pick a public framework, you will end up with a framework anyway: your own.” “If you don't pick a public framework, you should commit to building one on purpose, not by accident” Ryan Florence http:/ /blog.ryanflorence.com/you-cant-not-have-a-framework.html

Slide 71

Slide 71 text

Difícil deve se tornar fácil e fácil deve se tornar trivial

Slide 72

Slide 72 text

• Proteção contra CSRF • SQL Injection • Compressão • Connection Pooling • XSS • …

Slide 73

Slide 73 text

• Eventos • AJAX • Feature detection • Date/Time (╯°□°)╯︵ ┻━┻ • …

Slide 74

Slide 74 text

• Package Manager? • Module Loader? • MVC Framework? • Test Framework? • Task Runner? • CSS Architecture? • …

Slide 75

Slide 75 text

•Module Loader?

Slide 76

Slide 76 text

ES 6 ftw

Slide 77

Slide 77 text

• Package Manager? • Module Loader? • MVC Framework? • Test Framework? • Task Runner? • CSS Architecture? • …

Slide 78

Slide 78 text

4 Comunidades

Slide 79

Slide 79 text

Rails não é uma ilha

Slide 80

Slide 80 text

Nenhum desenvolvedor é uma ilha

Slide 81

Slide 81 text

Nenhuma comunidade é uma ilha

Slide 82

Slide 82 text

Tem muita coisa legal rolando por aí

Slide 83

Slide 83 text

Elixir Go Scala Ruby Python Clojure Rust Swift

Slide 84

Slide 84 text

Obrigado! https:/ /twitter.com/lucasmazza https:/ /speakerdeck.com/lucas