Skip to content

Instantly share code, notes, and snippets.

@LukasBombach
Created January 15, 2018 22:56
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save LukasBombach/38b5b1f19da819e6f4effee743162c6d to your computer and use it in GitHub Desktop.
Save LukasBombach/38b5b1f19da819e6f4effee743162c6d to your computer and use it in GitHub Desktop.
const path = require('path');
// const nodeExternals = require('webpack-node-externals');
module.exports = {
entry: {
index: ['./src/index.ts'],
},
output: {
path: path.join(__dirname, 'dist'),
filename: '[name].js',
library: 'write-js',
libraryTarget: 'umd',
umdNamedDefine: true,
},
devtool: 'source-map',
module: {
loaders: [
{ test: /\.tsx?$/, loader: require.resolve('awesome-typescript-loader') },
{ test: /\.jsx?$/, loader: 'babel-loader', exclude: /node_modules/ },
],
},
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment