-zvbog
Last Updated: April 14, 2016
·
152
· szymonkor
Zrzut ekranu z 2016 04 16 07 43 55

Responsive web components

SOURCE: http://www.sitepoint.com/responsive-web-components
Author describes few approaches to make web components responsive.

  • media queries
  • flexbox
  • element queries, like: .form__item[max-width~="30em"] {... Try this library: http://elementqueries.com/
  • :host element's attributes (this is really cool idea) CSS => :host([layout = "small"]) .form__item, HTML => <subscribe-form layout="small"></subscribe-form>. :host element is an element containing web component.
Say Thanks
Respond