In the last two years I've been speaking a lot about web components and Polymer in conferences and user-groups, sharing a vision of the upcoming web-component revolution. But after these introductory talks I often got the same question: "that seems great... but does it works in Real Life?" Ah, the pesky real life question...
In this talk I'm going to tackle that question in the best way I know: I'm going to tell you my experience of almost two full years web applications with Polymer in the real life, for real projects in a real enterprise with real costumers, and all the lessons I've learnt from it.
You will heard why did I choose Polymer, how I dealt with the 0.x versions lifecycle, the good points and the bad ones too, how I did integrate lots of 3rd part libs into a component architecture and how now I'm able to create full fledge Progressive Web Apps using Polymer in a simple way without having to deal with the complexity of Angular/React/Whatever JS, but also how to integrate your components into those frameworks if needed.
11. #DevoxxFR
A software platform that
• Ingests and stores data
• Manipulates and analyzes data
• Is dedicated to data from sensors, meters, IoT
and any real or virtual probe
Warp 10
21. #DevoxxFR
But it wasn't in 2014
We put our first Polymer app in production on 2014 with Polymer 0.4
Full story: http://blog.cityzendata.com/2015/02/07/behind-CES-colors/
22. #DevoxxFR
CES colors was quite a challenge
And it worked!
● Technology wasn't mature and changed quickly
○ We followed the evolution and updated the app often
● Cross-browsing rendering and full responsiveness needed
○ On computer & smartphone, Android & iPhone…
● Rich graphic components using canvas et SVG
○ First experience integrating libraries in Polymer
25. #DevoxxFR
Quantum is a complete application
● Write and execute WarpScript scripts, plot results
○ Integrating non Polymer libraries : nvd3, ace editor…
○ Many custom components
● Several vues to execute WarpScript and to push and delete data
○ A router is needed
■ At first page.js was encapsulated in a Polymer element
■ Then we changed to excess-router, done with Polymer
■ Soon changing aghain for the official solution, carbon-route
● Lots of components, lots of imports
○ Vulcanize used to build the releases
○ Sharding used to avoid monolithic approach and to make easier
element re-use
27. #DevoxxFR
Functionally rich
● Widget must be integrable everywhere
○ From full Polymer apps to plain old static pages, from AngularJS to ReactJS
○ Even in Apache Zeppelin notebooks
(B.O.F. RiakTS/WarpScript on thursday evening)
○ Any modern browser, with reasonable performances
● Several modes
○ Either sending WarpScript to a Warp 10 to get data or
Receiving data from other components / applications
○
● Lots of components, lots of imports
○ Vulcanize used to build the releases
○ Sharding used to avoid monolithic approach and to make easier
element re-use
28. #DevoxxFR
Widgets, apps, one shots
And a beer-themed
tutorial: Polymer-beers
I've just done a hands-on lab
on Polymer-beers this afternoon