1.0.0 • Published 2 years ago
git-revision-html-webpack-plugin v1.0.0
git-revision-html-webpack-plugin
Webpack plugin can generate the latest git commit hash within html meta tag, which is helpful when checking whether the deployment meets the expectations. It requires html-webpack-plugin.
Installation
npm install git-revision-html-webpack-plugin --save-dev
Usage
const HtmlWebpackPlugin = require('html-webpack-plugin');
const GitRevisionPlugin = require('git-revision-html-webpack-plugin');
module.exports = {
plugins: [
new HtmlPlugin(),
new GitRevisionPlugin()
]
}
Output:
<html>
<head>
<meta name="git-revision" content="eabf661">
</head>
</html>
1.0.0
2 years ago