feat(main): Add base theme: This is the falcon theme out of the box.
This is falcon v3.1.2
This commit is contained in:
21
falcon/_dev/js/theme/components/Lazyload.js
Normal file
21
falcon/_dev/js/theme/components/Lazyload.js
Normal file
@ -0,0 +1,21 @@
|
||||
import LazyLoad from 'vanilla-lazyload';
|
||||
|
||||
class PageLazyLoad {
|
||||
constructor({ selector = '.lazyload' } = {}) {
|
||||
this.selector = selector;
|
||||
this.lazyLoadInstance = null;
|
||||
this.init();
|
||||
}
|
||||
|
||||
init() {
|
||||
this.lazyLoadInstance = new LazyLoad({
|
||||
elements_selector: this.selector,
|
||||
});
|
||||
}
|
||||
|
||||
update() {
|
||||
this.lazyLoadInstance.update();
|
||||
}
|
||||
}
|
||||
|
||||
export default PageLazyLoad;
|
||||
Reference in New Issue
Block a user