Skip to content
PluginStats

billd-html-webpack-plugin weekly downloads statistics

By galaxy-s10 · npm · Webpack plugins

给你的项目注入构建信息~

View on npm Fresh · Oct 18, 2026

billd-html-webpack-plugin has 35 recorded weekly downloads on npm, a decrease of 60.2% over the past 30 days, ranking #1851 of 2,322 tracked listings.

Weekly downloads
35
Official API · Oct 18, 2026
7-day growth
-79.7%
-137 weekly downloads
30-day growth
-60.2%
-53 weekly downloads
90-day growth
+59.1%
+13 weekly downloads
Rank
#1851
Among tracked npm listings

About billd-html-webpack-plugin

<p align="center"> <a href=""> <img width="200" src="https://resource.hsslive.cn/image/1613141138717Billd.webp" alt="billd-html-webpack-plugin logo" /> </a> </p> <h1 align="center"> billd-html-webpack-plugin </h1> <p align="center"> 给你的项目注入构建信息 </p> <div align="center"> <a href="https://www.npmjs.com/package/billd-html-webpack-plugin"><img src="https://img.shields.io/npm/v/billd-html-webpack-plugin.svg" alt="Version"></a> <a href="https://www.npmjs.com/package/billd-html-webpack-plugin"><img src="https://img.shields.io/npm/dw/billd-html-webpack-plugin.svg" alt="Downloads"></a> <a href="https://www.npmjs.com/package/billd-html-webpack-plugin"><img src="https://img.shields.io/npm/l/billd-html-webpack-plugin.svg" alt="License"></a> </div>

简介

一个给你的项目注入构建信息的 webpack / vite 插件,兼容 nuxt2/3/4、vuecli4/5、webpack4/5、vite4、next12

效果

https://resource.hsslive.cn/image/b1c7975436bfbe9a79ffe862a31c8440.webp

从控制台可以看到,打印了当前项目的 git 信息以及最后部署时间,非常人性化,再也不用担心部署的代码是不是最新的了~

原理

  • nuxt2、vuecli4 是基于 webpack4 的,主要是根据 compiler.hooks.emit 这个钩子,在入口文件注入项目信息然后再输出
  • next12、vuecli5 是基于 webpack5 的,主要是根据 compiler.hooks.compilation 这个钩子以及 compilation.hooks.processAssets, 对入口文件进行注入项目信息然后再输出
  • nuxt3 是基于 vite 的,主要是根据 configResolved 这个钩子( vite 插件特有),通过 configResolved 钩子找入口,然后使用 transform 钩子(rollup 插件)将项目信息注入到入口文件
  • vite4,主要是根据 transformIndexHtml 这个钩子(vite 插件特有),对 index.html 注入项目信息

本质上就是给你的项目入口/所有 html 插入一串 js 代码。

安装

npm i billd-html-webpack-plugin --save-dev

使用前注意

请确保你的 package.json 里面有以下字段:

{
  "name": "xxxxxxxxxx",
  "version": "xxxxxxxxxx",
  "repository": {
    "type": "xxxxxxxxxx",
    "url": "xxxxxxxxxx"
  }
}

使用

nuxt2

nuxt.config.js

import BilldHtmlWebpackPlugin from 'billd-html-webpack-plugin';

export default {
  // ...
  build: {
    plugins: [
      // ...
      new BilldHtmlWebpackPlugin({ env: 'nuxt2' }),
    ],
  },
};

nuxt3

nuxt.config.ts

import BilldHtmlWebpackPlugin from 'billd-html-webpack-plugin';

// https://nuxt.com/docs/api/configuration/nuxt-config
export default defineNuxtConfig({
  // ...
  vite: {
    // ...
    plugins: [
      // ...
      new BilldHtmlWebpackPlugin({ env: 'nuxt3' }).config,
    ],
  },
});

nuxt3.6+

nuxt.config.ts

import BilldHtmlWebpackPlugin from 'billd-html-webpack-plugin';

// https://nuxt.com/docs/api/configuration/nuxt-config
export default defineNuxtConfig({
  // ...
  vite: {
    // ...
    plugins: [
      // ...
      new BilldHtmlWebpackPlugin({ env: 'nuxt3-6' }).config,
    ],
  },
});

vuecli4

vue.config.js

const BilldHtmlWebpackPlugin = require('billd-html-webpack-plugin').default;

module.exports = {
  // ...
  chainWebpack: (config) => {
    // ...
    config
      .plugin('billd-html-webpack-plugin')
      .use(BilldHtmlWebpackPlugin, [{ env: 'vuecli4' }]);
  },
};

vuecli5

vue.config.js

const { defineConfig } = require('@vue/cli-service');
const BilldHtmlWebpackPlugin = require('billd-html-webpack-plugin').default;

module.exports = defineConfig({
  // ...
  chainWebpack: (config) => {
    // ...
    config
      .plugin('billd-html-webpack-plugin')
      .use(BilldHtmlWebpackPlugin, [{ env: 'vuecli5' }]);
  },
});

webpack4

webpack.config.js

const HtmlWebpackPlugin = require('html-webpack-plugin');
const BilldHtmlWebpackPlugin = require('billd-html-webpack-plugin').default;

module.exports = {
  // ...
  plugins: [
    // ...
    new HtmlWebpackPlugin(),
    // 请确保billd-html-webpack-plugin插件在html-webpack-plugin插件后面
    new BilldHtmlWebpackPlugin({ env: 'webpack4' }),
  ],
};

webpack5

webpack.config.js

const HtmlWebpackPlugin = require('html-webpack-plugin');
const BilldHtmlWebpackPlugin = require('billd-html-webpack-plugin').default;

module.exports = {
  // ...
  plugins: [
    // ...
    new HtmlWebpackPlugin(),
    // 请确保billd-html-webpack-plugin插件在html-webpack-plugin插件后面
    new BilldHtmlWebpackPlugin({ env: 'webpack5' }),
  ],
};

next12

next.config.js

const BilldHtmlWebpackPlugin = require('billd-html-webpack-plugin').default;

const nextConfig = {
  // ...
  webpack: (config) => {
    config.plugins = [
      ...config.plugins,
      // ...
      new BilldHtmlWebpackPlugin({ env: 'next12' }),
    ];
    return config;
  },
};

module.exports = nextConfig;

vite4

vite.config.ts

import BilldHtmlWebpackPlugin from 'billd-html-webpack-plugin';
import { defineConfig } from 'vite';

// https://vitejs.dev/config/
export default defineConfig({
  // ...
  plugins: [
    // ...
    new BilldHtmlWebpackPlugin({ env: 'vite4' }).config,
  ],
});

注意:如果 package.json 里面配置了 "type": "module" ,则需要添加.default:new BilldHtmlWebpackPlugin.default({ env: 'vite4' }).config

配置

打印选项

import BilldHtmlWebpackPlugin from 'billd-html-webpack-plugin';

new BilldHtmlWebpackPlugin({
  env: 'nuxt2',
  log: {
    pkgName: true, // pkg名称
    pkgVersion: true, // pkg版本
    pkgRepository: false, // 不显示pkg仓库
    commitSubject: false, // 不显示git提交主题
    commitBranch: true, // git提交分支
    committerDate: true, // git提交日期
    commitHash: true, // git提交哈希
    committerName: true, // git提交者名字
    committerEmail: true, // git提交者邮箱
    lastBuildDate: true, // 最后构建日期
  },
});

获取打印数据

注意:只支持在 node 环境执行

import { logData } from 'billd-html-webpack-plugin';

console.log(
  logData({
    pkgRepository: false, // 不显示pkg仓库
  })
);
// {
//   pkgName: 'xxxxx',
//   pkgVersion: '0.0.1',
//   pkgRepository: '',
//   commitSubject: 'xxxxxx',
//   commitBranch: 'feat-webrtc',
//   committerDate: '2023-01-06 20:58:03 +0800',
//   commitHash: 'dsggggsdgdsgsdgs',
//   committerName: 'shuisheng',
//   committerEmail: '2274751790@qq.com',
//   lastBuildDate: '2023/1/10 11:11:56',
// };

调试

  • 查看列表
pnpm list --global
  • 卸载…

Description from the npm listing.

  • billd
  • webpack-plugin
  • html-webpack-plugin

README badge

Show your rank in a README or on your website. The badge updates automatically.

Charts

Images: 30d · 1y · all time · 1600×900 dark

Adoption over time

billd-html-webpack-plugin weekly downloads on npm, last 90 days: 35 weekly downloads as of Oct 18, 2026, +59.1% over 90 days.billd-html-webpack-pluginWeekly downloads on npm · Last 90 days35downloads / week+59.1% over 90 days050100150200250300350Jul 20Aug 4Aug 19Sep 3Sep 18Oct 3Oct 18downloads / weekobservedarchived (Internet Archive)no observationsJul 22, 2026 – Oct 18, 2026 · 89 observations · Updated Oc…pluginstats.com
billd-html-webpack-plugin weekly downloads on npm, last 90 days: 35 weekly downloads as of Oct 18, 2026, +59.1% over 90 days.

7/30/90-day growth

billd-html-webpack-plugin weekly downloads growth on npm: -79.7% over 7 days, -60.2% over 30 days, +59.1% over 90 days.billd-html-webpack-pluginWeekly downloads growth on npm35downloads / week now7-day growth-137 weekly downloads-79.7%30-day growth-53 weekly downloads-60.2%90-day growth+13 weekly downloads+59.1%Growth vs. nearest observation to each baseline date · Updated Oct 18, 2026pluginstats.com
billd-html-webpack-plugin weekly downloads growth on npm: -79.7% over 7 days, -60.2% over 30 days, +59.1% over 90 days.

Ranking history

billd-html-webpack-plugin npm ranking history: currently #1851 (by weekly downloads).billd-html-webpack-pluginnpm ranking · by weekly downloads · Last 90 days#1851current rank#1700#1720#1740#1760#1780#1800#1820#1840#1860Jul 22Aug 6Aug 21Sep 5Sep 20Oct 5Oct 20rankOct 18, 2026 – Oct 20, 2026 · 3 observations · Updated Oct 18, 2026pluginstats.com
billd-html-webpack-plugin npm ranking history: currently #1851 (by weekly downloads).

Listing placement

All npm2,320 listings · 116 pages · 1,161 shown · page 93, #15 (overall #1,855)
All npm: every listing in weekly downloads order

Listing placement

Webpack plugins251 listings · 13 pages · page 7, #19 (overall #139)
Webpack plugins: every listing in weekly downloads order

Filled points are observed values; hollow points come from Internet Archive snapshots of the listing page. Dashed segments span periods with no observations — values between points are not interpolated.

Each band is one page of 20. Weekly downloads on a linear scale. Placement is projected from weekly downloads, so it can differ from the marketplace's own sort order. Hover a dot to see the listing.

Recent observations

Full history (122)
Recent weekly downloads observations for billd-html-webpack-plugin
Date (UTC)Weekly downloadsChange vs. previous
35-19
54-3
57+7
50-46
96-83
1790
179+7
172+16
156-70
226-28
254+41
213+49
164-7
171—

Similar npm Webpack plugins plugins

All 20 billd-html-webpack-plugin alternatives

Data source

Weekly downloads (trailing 7 complete days) come from the official npm downloads API. Downloads include CI and mirrors and are not equivalent to installs or users. npm publishes no ratings.

Listing: https://www.npmjs.com/package/billd-html-webpack-plugin. First seen Oct 16, 2026; last successful collection Oct 20, 2026. See the methodology.