4.0.6 • Published 6 years ago

vue-responsive-img v4.0.6

Weekly downloads
2
License
MIT
Repository
github
Last release
6 years ago

VUE-RESPONSIVE-IMG

Generates img element with responsive attributes

Props

  1. sources: Array = [], list of source files and sizes, according to srcset dependency
  2. baseUrl: String = '', common url to prefix every url in sources
  3. src: Number = 0, sources element index for fallback url
  4. sizes: String | Array = '100vw', list of mappings between screen size breakpoints and image sizes, as in MDN

Accepts all regular img attributes

Output (taken from MDN):
<img srcset="elva-fairy-320w.jpg 320w,
             elva-fairy-480w.jpg 480w,
             elva-fairy-800w.jpg 800w"
     sizes="(max-width: 320px) 280px,
            (max-width: 480px) 440px,
            800px"
     src="elva-fairy-800w.jpg" alt="Elva dressed as a fairy">
4.0.6

6 years ago

4.0.5

6 years ago

4.0.4

6 years ago

4.0.3

6 years ago

4.0.2

6 years ago

4.0.1

6 years ago

4.0.0

6 years ago

3.1.2

6 years ago

3.1.1

6 years ago

3.1.0

6 years ago

3.0.8

6 years ago

3.0.7

6 years ago

3.0.6

6 years ago

3.0.5

6 years ago

3.0.4

6 years ago

3.0.3

6 years ago

3.0.2

6 years ago

3.0.1

6 years ago

3.0.0

6 years ago

2.0.1

6 years ago

2.0.0

6 years ago

1.0.3

6 years ago

1.0.2

6 years ago

1.0.1

6 years ago

1.0.0

6 years ago