{"size": 843, "ext": "js", "max_stars_repo_path": "webpack.config.js", "max_stars_repo_name": "mahdykhayyamian/smartframes", "max_stars_repo_stars_event_min_datetime": null, "max_stars_repo_stars_event_max_datetime": null, "max_issues_repo_path": "webpack.config.js", "max_issues_repo_name": "mahdykhayyamian/smartframes", "max_issues_repo_issues_event_min_datetime": null, "max_issues_repo_issues_event_max_datetime": null, "max_forks_repo_path": "webpack.config.js", "max_forks_repo_name": "mahdykhayyamian/smartframes", "max_forks_repo_forks_event_min_datetime": null, "max_forks_repo_forks_event_max_datetime": null}
{"max_stars_count": null, "max_issues_count": null, "max_forks_count": null, "avg_line_length": 24.7941176471, "max_line_length": 53, "alphanum_fraction": 0.4685646501}
var webpack = require('webpack');
var path = require('path');

var PROD = JSON.parse(process.env.PROD_ENV || '0');

module.exports = {
    entry:  __dirname + '/src/index.js',
    output: {
        path: path.resolve(__dirname, 'dist'),
        filename: 'smart-frames.js',
        library: 'smartframes',
        libraryTarget: 'umd'
    },
    module: {
        rules: [{
            test: /\.css$/,
            use: ['style-loader', 'css-loader']
        }, {
            test: /\.js$/,
            use: [{
                loader: 'babel-loader',
                options: { presets: ['es2015'] }
            }],
        }]
    },
    plugins: PROD ? [
        new webpack.optimize.UglifyJsPlugin({
            compress: { warnings: false }
        })
    ] : [],
    resolve: {
        modules: [__dirname, 'client','node_modules']
    }
};