feat: server profile support

This commit is contained in:
cha0s 2019-04-12 13:44:56 -05:00
parent 22737994ea
commit 93550c33d7

View File

@ -19,8 +19,13 @@ config.externals = [
whitelist: /@avocado/, whitelist: /@avocado/,
}), }),
]; ];
const nodeArgs = [];
if (process.argv.find((arg) => '--prof' === arg)) {
nodeArgs.push('--prof');
}
config.plugins.push(new StartServerPlugin({ config.plugins.push(new StartServerPlugin({
name: 'server.js', name: 'server.js',
nodeArgs: nodeArgs,
restartable: false, restartable: false,
})); }));
config.target = 'node'; config.target = 'node';