Created
April 18, 2019 13:15
-
-
Save khayyamsaleem/957fa0e314df0a844495d604fe6f9bbc to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* eslint-disable filenames/match-regex, import/no-commonjs */ | |
const path = require('path'); | |
const context = path.resolve(__dirname, 'src'); | |
module.exports = { | |
context, | |
entry: './index.js', | |
module: { | |
rules: [ | |
{ | |
include: path.resolve(__dirname, './src'), | |
loaders: [ | |
'style-loader', | |
'css-loader?modules&localIdentName=[path]___[name]__[local]___[hash:base64:5]' | |
], | |
test: /\.css$/ | |
}, | |
{ | |
include: path.resolve(__dirname, './src'), | |
loader: 'babel-loader', | |
test: /\.js$/ | |
} | |
] | |
}, | |
output: { | |
libraryTarget: 'umd', | |
path: path.resolve(__dirname, './dist'), | |
filename: 'index.js' | |
}, | |
stats: 'minimal' | |
}; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment