add optimizeSpeed image-rendering attr, formatting

This commit is contained in:
Tomáš Mládek 2021-01-09 21:00:30 +01:00
parent 4531d12671
commit fee57e4b3b

View file

@ -40,7 +40,7 @@ export default defineComponent({
const element = entry.target as HTMLImageElement;
element.src = element.dataset.src!;
}
})
});
}, {rootMargin: "100px"});
Array.from((root.value as Element).children).forEach((el) => {
observer.observe(el);
@ -84,9 +84,6 @@ function getMeta(url: string): Promise<HTMLImageElement> {
<style scoped>
.video-scroll img {
position: absolute;
}
.initial {
background: red;
image-rendering: optimizeSpeed;
}
</style>