UNPKG

@cumulus/hyrax-metadata-updates

Version:
45 lines (43 loc) 952 B
const path = require('path'); // path to module root const root = path.resolve(__dirname); module.exports = { mode: process.env.PRODUCTION ? 'production' : 'development', entry: './index.js', output: { chunkFormat: false, libraryTarget: 'commonjs2', filename: 'index.js', path: path.resolve(__dirname, 'dist'), devtoolModuleFilenameTemplate: (info) => { const relativePath = path.relative(root, info.absoluteResourcePath) return `webpack://${relativePath}`; } }, externals: [ /@aws-sdk\//, 'electron', {'formidable': 'url'} ], module: { rules: [ { test: /\.js$/, exclude: /node_modules/, use: [ { loader: 'babel-loader', options: { cacheDirectory: true }, }, ], }, ], }, devtool: 'inline-source-map', target: 'node', optimization: { nodeEnv: false } };