Skip to content

Commit

Permalink
docs: add html-webpack-plugin
Browse files Browse the repository at this point in the history
  • Loading branch information
chenjiahan committed Aug 16, 2024
1 parent 40bb499 commit c8dcc50
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
4 changes: 4 additions & 0 deletions website/docs/en/guide/optimization/profile.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,10 @@ If your project uses the PostCSS plugin for Tailwind CSS v3, you may need to wai

[less-loader](https://github.com/webpack-contrib/less-loader) compiles `.less` files based on Less. Since Less currently lacks an officially implemented high performance alternative, it is recommended to use [sass-loader](https://github.com/webpack-contrib/sass-loader) and [sass-embedded](https://www.npmjs.com/package/sass-embedded) instead. `sass-embedded` is a JavaScript wrapper for Sass's native Dart executable that provides excellent performance.

### html-webpack-plugin

[html-webpack-plugin](https://github.com/jantimon/html-webpack-plugin) performs poorly when generating large numbers of HTML files. The [HtmlRspackPlugin](/plugins/rspack/html-rspack-plugin) implemented in Rust by Rspack can provide better performance.

## Rspack Profile

<ApiMeta addedVersion={'0.3.0'} />
Expand Down
4 changes: 4 additions & 0 deletions website/docs/zh/guide/optimization/profile.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,10 @@ import { ApiMeta, Stability } from '@components/ApiMeta.tsx';

[less-loader](https://github.com/webpack-contrib/less-loader) 基于 Less 来编译 `.less` 文件,由于 Less 目前没有官方实现的高性能替代方案,建议使用 [sass-loader](https://github.com/webpack-contrib/sass-loader)[sass-embedded](https://www.npmjs.com/package/sass-embedded) 代替,sass-embedded 是 Sass 原生 Dart 可执行文件的 JavaScript wrapper,具备出色的性能。

### html-webpack-plugin

[html-webpack-plugin](https://github.com/jantimon/html-webpack-plugin) 在生成大量 HTML 文件时,性能表现不佳,Rspack 基于 Rust 实现的 [HtmlRspackPlugin](/plugins/rspack/html-rspack-plugin) 可以提供更好的性能。

## Rspack Profile

<ApiMeta addedVersion={'0.3.0'} />
Expand Down

0 comments on commit c8dcc50

Please sign in to comment.