text: var webpack = require('webpack');
  var env = process.env.NODE_ENV;
  
  var reactExternal = {
    root: 'React',
    commonjs2: 'react',
    commonjs: 'react',
    amd: 'react'
  };
  
  var plugins = [
  new webpack.DefinePlugin({
    'process.env.NODE_ENV': JSON.stringify(env)
  }),
  new webpack.optimize.OccurenceOrderPlugin()
  ];
  
  if (env === 'production') {
    plugins.push(
      new webpack.optimize.UglifyJsPlugin({
        compressor: {
          screw_ie8: true,
          warnings: false
        }
      })
      );
  }
  
  module.exports = {
    externals: {
      react: reactExternal
    },
    module: {
      loaders: [
      { test: /\.js$/, loaders: ['babel-loader'], exclude: /node_modules/ },
      { test: /\.png$/, loader: "url-loader?mimetype=image/png" }, 
      { test: /\.gif$/, loader: "url-loader" }
      ]
    },
    output: {
      library: 'AsyncDataLoader',
      libraryTarget: 'umd'
    },
    plugins: plugins,
    resolve: {
      extensions: ['', '.js']
    }
  };