![Oracle Drags Its Feet in the JavaScript Trademark Dispute](https://cdn.sanity.io/images/cgdhsj6q/production/919c3b22c24f93884c548d60cbb338e819ff2435-1024x1024.webp?w=400&fit=max&auto=format)
Security News
Oracle Drags Its Feet in the JavaScript Trademark Dispute
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
@asspixel/html-webpack-harddisk-plugin
Advanced tools
Write html files to hard disk even when using the webpack dev server or middleware
Enhances html-webpack-plugin
functionality by adding the {alwaysWriteToDisk: true|false}
option.
This is an extension plugin for the webpack plugin html-webpack-plugin - a plugin that simplifies the creation of HTML files to serve your webpack bundles.
You must be running webpack on node 0.12.x or higher
Install the plugin with npm:
$ npm install --save-dev html-webpack-harddisk-plugin
Require the plugin in your webpack config:
var HtmlWebpackHarddiskPlugin = require('html-webpack-harddisk-plugin');
Add the plugin to your webpack config as follows:
plugins: [
new HtmlWebpackPlugin(),
new HtmlWebpackHarddiskPlugin()
]
The above configuration will actually do nothing due to the configuration defaults.
As soon as you now set alwaysWriteToDisk
to true
the generated output of the HtmlWebpackPlugin will
always be written to disk. This is very useful if you want to pick up the output with another middleware.
plugins: [
new HtmlWebpackPlugin({
alwaysWriteToDisk: true
}),
new HtmlWebpackHarddiskPlugin()
]
Even if you generate multiple files make sure that you add the HtmlWebpackHarddiskPlugin only once:
plugins: [
new HtmlWebpackPlugin({
alwaysWriteToDisk: true
}),
new HtmlWebpackPlugin({
alwaysWriteToDisk: true,
filename: 'demo.html'
}),
new HtmlWebpackPlugin({
alwaysWriteToDisk: false,
filename: 'test.html'
}),
new HtmlWebpackHarddiskPlugin()
]
If you need to set the output path explicitly (for example when using with webpack-dev-server middleware) then pass in the outputPath
option:
new HtmlWebpackHarddiskPlugin({
outputPath: path.resolve(__dirname, 'views')
})
FAQs
Write html files to hard disk even when using the webpack dev server or middleware
The npm package @asspixel/html-webpack-harddisk-plugin receives a total of 0 weekly downloads. As such, @asspixel/html-webpack-harddisk-plugin popularity was classified as not popular.
We found that @asspixel/html-webpack-harddisk-plugin demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
Security News
The Linux Foundation is warning open source developers that compliance with global sanctions is mandatory, highlighting legal risks and restrictions on contributions.
Security News
Maven Central now validates Sigstore signatures, making it easier for developers to verify the provenance of Java packages.