Add Rehype Plugin to lazy images
This commit is contained in:
@@ -1,5 +1,6 @@
|
||||
import getReadingTime from 'reading-time';
|
||||
import { toString } from 'mdast-util-to-string';
|
||||
import lazyLoadPlugin from 'rehype-plugin-image-native-lazy-loading'
|
||||
|
||||
export function readingTimeRemarkPlugin() {
|
||||
return function (tree, file) {
|
||||
@@ -34,3 +35,5 @@ export function responsiveTablesRehypePlugin() {
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
export const lazyImagesRehypePlugin = lazyLoadPlugin
|
||||
|
Reference in New Issue
Block a user