0.4.2 • Published 6 years ago
vue-rokka-image-lazy v0.4.2
vue-rokka-image-lazy
Loads images lazy from rokka
It's compatible to vue-rokka-image.
It uses the pretty small lozad library.
Demo
jsFiddle / jsFiddle with rokka.js
Installation
npm install rokka-io/vue-rokka-image-lazy --saveUsage
It has the same properties as vue-rokka-image, so just replace the import and maybe tagname to get lazyloading
It also adds srcset for 1x and 2x. You can overwrite that with the postfix and options properties.
It additionally suppports a loading property, which should point to a loading image
<template>
<rokka-img-lazy-load
alt="alt Text"
:title="Title"
:organization="rokkaOrg"
:stack="'resizecrop'"
:hash="HASH"
:format="jpg"
filename="image.jpg"
:loading="loadingImage"
/>
</template>
<script>
import { RokkaImageImgLazy } from 'vue-rokka-image-lazy';
export default {
components: {
RokkaImageImgLazy,
},
data() {
return {
loadingImage: process.env.BASE_URL + '/assets/loading.gif',
};
}
}
</script>Development from within a Vue.js project
- Go to component folder
- change
maininpackage.jsontomain: "src/index.js" npm link- Go to project folder
npm link vue-rokka-image-lazyet voila
0.4.2
6 years ago
0.4.1
6 years ago
0.4.0
6 years ago
0.0.25
6 years ago
0.0.24
6 years ago
0.0.23
6 years ago
0.0.21
6 years ago
0.0.20
6 years ago
0.0.19
6 years ago
0.0.18
6 years ago
0.0.17
6 years ago
0.0.16
6 years ago
0.0.15
6 years ago
0.0.14
6 years ago
0.0.13
6 years ago
0.0.11
6 years ago
0.0.10
6 years ago
0.0.9
6 years ago
0.0.8
6 years ago
0.0.7
6 years ago
0.0.6
6 years ago
0.0.5
6 years ago
0.0.4
6 years ago