Tomomi (@girlie_mac) is an avid open web advocate and front-end UX engineer, who has been in active in the mobile-space since before it was cool. She is currently working as a developer evangelist at PubNub in San Francisco, and mostly providing use cases and ideas with the data stream APIs by writing demos and technical articles.
Divs, nested divs and more nested divs… A pretty web UI with nasty markups is a big turn-off. Now with a new set of new W3C web platform primitives called Web Components, we can encapsulate UI and complex functionalities, just like packing data and functions into a single component, and restrict the access in object-oriented programming. The web components don’t add ugly children in your DOM tree, in fact, they are separated from the tree. The DOM-related methods like getElementById() doesn’t give you an access inside! So, how can you use the encapsulated components and also obtain the access inside and style them?