File: createBenchmark.js

package info (click to toggle)
node-webpack 4.43.0-6~bpo10%2B1
  • links: PTS, VCS
  • area: main
  • in suites: buster-backports
  • size: 21,220 kB
  • sloc: javascript: 69,992; makefile: 22
file content (28 lines) | stat: -rw-r--r-- 566 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
const webpack = require("../");
const path = require("path");

webpack(
	{
		context: __dirname,
		entry: "./createBenchmark/entry.js",
		output: {
			path: __dirname,
			filename: "benchmark-bundle.js"
		},
		target: "node",
		node: {
			__dirname: false
		},
		plugins: [
			new webpack.NamedModulesPlugin(),
			new webpack.IgnorePlugin(/^(fsevents|uglify-js)$/),
			new webpack.NormalModuleReplacementPlugin(
				/^.\/loadLoader$/,
				path.resolve(__dirname, "./createBenchmark/loadLoader")
			)
		]
	},
	(err, stats) => {
		console.log(stats.toString());
	}
);