Important: This documentation covers Yarn 1 (Classic).
For Yarn 2+ docs and migration guide, see yarnpkg.com.

Package detail

@mdit/plugin-img-lazyload

mdit-plugins18.6kMIT0.22.1TypeScript support: included

img-lazyload plugin for MarkdownIt

markdown-it, markdown-it-plugin, img-lazyload

readme

@mdit/plugin-img-lazyload

Version Downloads Size

Image lazyload plugin for MarkdownIt.

Docs | 文档

Install / 安装

# pnpm
pnpm add -D @mdit/plugin-img-lazyload
# npm
npm i -D @mdit/plugin-img-lazyload
# yarn
yarn add -D @mdit/plugin-img-lazyload

changelog

Change Log

All notable changes to this project will be documented in this file. See Conventional Commits for commit guidelines.

0.21.0 (2025-05-30)

✨ Features

  • align: provide browser bundle (1135f5f)
  • attr: provide browser bundle (74c0043)
  • icon: add browser bundle (690e957)
  • katex: add browser bundle (9f71b4d)
  • plantuml: use node native zlib module and provide browser bundle (03a0b6b)
  • sub: add browser bundle (98f60fe)
  • sup: add browser bundle (639dc8f)
  • tab: add browser bundle (1afdc8f)
  • uml: add browser bundle (f2f2be6)

🐛 Bug Fixes

0.20.0 (2025-05-27)

⚠ BREAKING CHANGES

  • tab: rename options
  • demo: rename beforeContent as showCodeFirst
  • mathjax-slim: throw if mathjax-full is not installed
  • include: throw if required option not set
  • snippet: throw if required option not set
  • demo: use stricter container
  • container: rebuild container to be stricter

✨ Features

  • container: rebuild container to be stricter (1c59e98)
  • demo: rename beforeContent as showCodeFirst (a9827a3)
  • demo: use stricter container (d7cbd1c)
  • include: throw if required option not set (99c5cf7)
  • katex: use console.error (cabf219)
  • mathjax-slim: throw if mathjax-full is not installed (97818a2)
  • snippet: throw if required option not set (24125bb)
  • tab: make tab container be stricter and improve test coverage (bf80e1c)
  • tab: rename options (8c2c1de)

🐛 Bug Fixes

  • demo: support working with include (a59236d)
  • snippet: support files without ext (7412023)

0.19.0 (2025-05-25)

✨ Features

  • img-size: improve label handling and allow working together, close #98 (e918a50)

0.18.1 (2025-05-16)

🐛 Bug Fixes

  • img-size: rebuild plugin to work with figure (e391c42)

0.18.0 (2025-05-01)

⚠ BREAKING CHANGES

  • img-size: rebuild img-size syntax
  • img-size: restore old img size format and move to alt
  • drop node18

✨ Features

  • drop node18 (0f7dd91)
  • img-size: mark legacyImgSize as deprecated (0adb063)
  • img-size: rebuild img-size syntax (196e177)
  • img-size: restore old img size format and move to alt (da5603b)
  • img-size: split original obsidian img size out and improve unit tests (6b4dc3b)

0.17.0 (2025-04-29)

⚠ BREAKING CHANGES

  • img-size: rebuild img size (#96)

✨ Features

0.16.8 (2025-03-05)

🐛 Bug Fixes

  • footnote: stop using self-closing syntax <a /> as it breaks in some HTML interpreters (#81) (783e25e)

0.16.7 (2025-01-25)

🐛 Bug Fixes

  • katex: fix \gdef for katex (7aea74c)

0.16.6 (2025-01-25)

⚠ BREAKING CHANGES

  • katex: rebuild mhchem support (178f3d1)

✨ Features

  • katex: rebuild mhchem support (178f3d1)

🐛 Bug Fixes

  • deps: update dependency katex to v0.16.21 [security] (#75) (f6ddfdf), closes #75

0.16.5 (2025-01-13)

🐛 Bug Fixes

  • icon: support attr with empty value (bf2d284)

0.16.4 (2025-01-13)

🐛 Bug Fixes

  • icon: fix attr extracting (a42c837)

0.16.3 (2025-01-13)

🐛 Bug Fixes

0.16.2 (2025-01-12)

🐛 Bug Fixes

  • katex: improve logger type (ba1a42c)

0.16.1 (2025-01-12)

🐛 Bug Fixes

  • katex: fix option types (72eb726)

0.16.0 (2025-01-12)

✨ Features

  • katex: improve error handling (c9ac80d)

🐛 Bug Fixes

  • tex: end block tex correctly (163aae1)

0.15.1 (2025-01-12)

🐛 Bug Fixes

0.15.0 (2025-01-11)

✨ Features

🐛 Bug Fixes

  • deps: update dependency @vuepress/plugin-docsearch to v2.0.0-rc.68 (#68) (2917ac4)
  • deps: update dependency katex to v0.16.19 (#69) (b6b236c)
  • spoiler: fix styles (659e87b)

0.14.0 (2024-11-28)

✨ Features

🐛 Bug Fixes

0.13.3 (2024-10-24)

0.13.2 (2024-09-24)

🐛 Bug Fixes

0.13.1 (2024-08-27)

🐛 Bug Fixes

0.13.0 (2024-08-03)

✨ Features

0.12.0 (2024-05-16)

✨ Features

  • add transformer option for tex plugins (f1b2f84)

0.11.0 (2024-05-13)

⚠ BREAKING CHANGES

  • img-mark: remove gh- classes as it's no longer supported by gfm
  • img-size: unify plugin export name

✨ Features

  • img-mark: remove gh- classes as it's no longer supported by gfm (8cf3ba9)
  • img-size: unify plugin export name (1e08784)

0.10.1 (2024-05-05)

🐛 Bug Fixes

  • demo: fix contentRender (cfffb20)

0.10.0 (2024-05-03)

✨ Features

0.9.0 (2024-04-17)

✨ Features

  • add plantuml plugin (3551afb)
  • update to markdown-it 14.1.0 and migrate to esm only (a7d7c22)

0.8.0 (2023-12-08)

✨ Features

  • support markdown-it v14 (ac32cf1)

0.7.6 (2023-12-07)

🐛 Bug Fixes

  • alert: correct alert detecting (9946286)

0.7.5 (2023-12-04)

🐛 Bug Fixes

  • mathjax: fix tex type issue (e856e90)

0.7.4 (2023-11-28)

🐛 Bug Fixes

  • demo: fix source getting (5860029)

0.7.3 (2023-11-26)

✨ Features

0.7.2 (2023-11-26)

🐛 Bug Fixes

  • alert: remove debug logging (572001e)

0.7.1 (2023-11-25)

🐛 Bug Fixes

  • alert: fix alert deep detect (1839b87)

0.7.0 (2023-11-24)

✨ Features

🚀 Performance Improvements

  • include: improve performance (2fcbb68)

0.6.5 (2023-11-03)

✨ Features

  • add allowInlineWithSpace options for katex and mathjax (911cdf2)
  • tex: add allowInlineWithSpace for tex (e6d9878)

0.6.4 (2023-11-03)

✨ Features

  • include: add useComment option (f1222ba)

0.6.3 (2023-11-02)

✨ Features

  • include: support frontmatter (462497f)

0.6.2 (2023-11-02)

🐛 Bug Fixes

0.6.1 (2023-11-02)

🐛 Bug Fixes

  • demo: fix validation issue (e2fa49d)

0.6.0 (2023-11-02)

✨ Features

0.5.2 (2023-10-24)

🐛 Bug Fixes

  • mathjax: remove exports (787a88f)

0.5.1 (2023-10-24)

🐛 Bug Fixes

0.5.0 (2023-10-16)

✨ Features

0.4.8 (2023-06-12)

✨ Features

  • katex: improve test coverage (f545bea)

0.4.7 (2023-06-05)

0.4.6 (2023-05-19)

✨ Features

  • tex: support mathFence option (60d1d68)

0.4.5 (2023-05-09)

0.4.4 (2023-04-28)

🐛 Bug Fixes

  • include: fix wrong path (27c8873)

0.4.3 (2023-04-07)

🐛 Bug Fixes

0.4.2 (2023-04-06)

✨ Features

  • katex: support logger option (9850d5e)

0.4.1 (2023-03-29)

✨ Features

  • include: improve grammar (e798dd3)

0.4.0 (2023-03-26)

⚠ BREAKING CHANGES

  • include: you should use <!-- @include :path --> now

✨ Features

  • include: update include syntax (fe5b2d8)

0.3.0 (2023-02-17)

⚠ BREAKING CHANGES

  • mathjax: add outputStyle method and remove generateMathjaxStyle

✨ Features

  • mathjax: add outputStyle method and remove generateMathjaxStyle (6fa0408)

🐛 Bug Fixes

  • mathjax: add reset method to clear label between pages, close #25 (d580f1b)

0.2.4 (2023-02-16)

✨ Features

  • add obsidianImageSize plugin (d20c16d)

0.2.3 (2023-01-01)

✨ Features

  • add plugin-snippet (c410e6d)
  • tex: throw error when render function is missing (0ce0efa)

🐛 Bug Fixes

  • include: fix dedent single line file (f84216f)
  • include: improve option types and fix error hint (30dc191)

0.2.2 (2022-12-29)

🐛 Bug Fixes

  • tab: fix multiple instance issue (907130b)

0.2.1 (2022-12-29)

✨ Features

  • tab: add index information (356c5a5)

0.2.0 (2022-12-29)

⚠ BREAKING CHANGES

  • include: rename getCurrentPath to currentPath rename getPath to resolvePath

✨ Features

  • add tab plugin (96d116a)
  • include: update options (7ccf4b9)
  • tasklist: add options for class name (cdc1ff6)

0.1.0 (2022-12-28)

✨ Features

0.1.0-alpha.1 (2022-12-28)

✨ Features