pegjs/webpack.config.js
2019-02-14 11:05:27 +00:00

38 lines
805 B
JavaScript

"use strict";
const target = require( "@pegjs/bundler/target" );
module.exports = [
/* packages/pegjs/dist/peg.js */
target( {
entry: require.resolve( "pegjs" ),
library: "peg",
output: "packages/pegjs/dist/peg.js",
} ),
/* packages/pegjs/dist/peg.min.js */
target( {
entry: require.resolve( "pegjs" ),
library: "peg",
output: "packages/pegjs/dist/peg.min.js",
} ),
/* https://pegjs.org/*-bundle.min.js */
target( {
entry: {
"benchmark": require.resolve( "@pegjs/benchmark-suite/browser.js" ),
"test": require.resolve( "@pegjs/spec-suite/browser.stub.js" ),
},
library: [ "peg", "[name]" ],
output: "docs/.vuepress/public/[name]-bundle.min.js",
} ),
];