html-webpack-plugin-inject-thyme-leaf-tags
v1.0.3
Published
A html webpack plugin to inject thymeleaf compatible template tags for script and style tags
Downloads
15
Maintainers
Readme
ThymeLeaf Tag Injector
A html webpack plugin to inject thymeleaf compatible template tags for script and style tags
Installation
yarn add -D html-webpack-plugin-inject-thyme-leaf-tags
or
npm install -D html-webpack-plugin-inject-thyme-leaf-tags
Usage example
import WebpackPluginInjectThymeTags from 'html-webpack-plugin-inject-thyme-leaf-tags';
under webpack config plugin section add
plugins: [
new HtmlWebpackPlugin({
template: path.join(__dirname, "src", "index.html"),
}),
new HtmlWebpackPluginInjectTags({
stylePrefix: "/static/",
scriptPrefix: "/static/",
}),
]
you can pass an empty object if no prefix is needed like this
new HtmlWebpackPluginInjectTags({})
or like this
new HtmlWebpackPluginInjectTags(),