managing frontend libs in your symfony project

11
Managing frontend libs in your Symfony project Massimiliano Arione SymfonyCon lighting talks Madrid, 2014

Upload: massimiliano-arione

Post on 07-Jul-2015

91 views

Category:

Software


0 download

DESCRIPTION

A brief list of possible solutions for the dependency hell problem with your frontend libs. Lighting talk at SymfonyCon Madrid 2014

TRANSCRIPT

Page 1: Managing frontend libs in your Symfony project

Managing frontend libs in your Symfony project

Massimiliano Arione

SymfonyCon lighting talksMadrid, 2014

Page 2: Managing frontend libs in your Symfony project

about me

CTO at bee-lab.net

PHP dev since ~2000fell in love with Symfony ~2007president of PUG Roma

https://twitter.com/garakkio

Page 3: Managing frontend libs in your Symfony project

problem

You need to manage some frontend libraries

Examples:❏ jquery❏ bootstrap❏ font awesome❏ you name it

Page 4: Managing frontend libs in your Symfony project

solution #1

ask your frontend colleague

PROSsuper simple

CONShe/she can do a messthere’s no frontend colleague

Page 5: Managing frontend libs in your Symfony project

solution #2

Put them in your repo

PROScomplete control over sources

CONSyou have to maintain vendors

Page 6: Managing frontend libs in your Symfony project

solution #3

Use CDNs

PROSsuper fast

CONSdoes not work when offlinenot everything is on a CDN

Page 7: Managing frontend libs in your Symfony project

solution #4

Use Composer

PROSyou are already using it (are you?)

CONSbackend and frontend mixedduplicated code

Page 8: Managing frontend libs in your Symfony project

solution #5

Use Bower

PROSjust declare vendors in your repo

CONSyou need node.js

Page 9: Managing frontend libs in your Symfony project

solution #6

Use BowerPHP

PROSjust declare vendors in your repo

CONS...

Page 10: Managing frontend libs in your Symfony project

thanks

http://www.bowerphp.org/