chore(lazyload): remove some legecy code (#8650)

This commit is contained in:
neverland
2021-05-02 11:49:32 +08:00
committed by GitHub
parent 819018ef68
commit 721ecb6e76
4 changed files with 4 additions and 36 deletions
+3 -4
View File
@@ -1,5 +1,5 @@
/* eslint-disable max-classes-per-file */
import { find, remove, ArrayFrom } from './util';
import { find, remove } from './util';
const defaultOptions = {
selector: 'img',
@@ -44,7 +44,7 @@ class LazyContainer {
}
getImgs() {
return ArrayFrom(this.el.querySelectorAll(this.options.selector));
return Array.from(this.el.querySelectorAll(this.options.selector));
}
clear() {
@@ -57,10 +57,9 @@ class LazyContainer {
}
}
export default class LazyContainerMananger {
export default class LazyContainerManager {
constructor({ lazy }) {
this.lazy = lazy;
lazy.lazyContainerMananger = this;
this._queue = [];
}