title: npm install jquery bootstrap but not working
body: <p>I used npm to install Bootstrap and jQuery and using webpack to bundle them, but when I'm loading up my page on http-server, I get "jQuery is not defined". Below is what I have in my component files and my json.package</p>
  
  <pre><code>npm install --save bootstrap
  npm install --save jquery
  
  
  require('bootstrap');
  window.$ = $;
  var $ = require('jquery');
  </code></pre>
  
  <p>//json.package</p>
  
  <pre><code>{
    "name": "API_Assignment",
    "version": "1.0.0",
    "description": "",
    "main": "index.js",
    "scripts": {
      "test": "echo \"Error: no test specified\" &amp;&amp; exit 1"
    },
    "keywords": [],
    "author": "",
    "license": "ISC",
    "dependencies": {
      "babel-core": "^6.7.2",
      "babel-loader": "^6.2.4",
      "babel-preset-react": "^6.5.0",
      "bootstrap": "^3.3.6",
      "jquery": "^2.2.1",
      "react": "^0.14.7",
      "react-addons-update": "^0.14.7",
      "react-dom": "^0.14.7",
      "react-router": "^2.0.1",
      "webpack": "^1.12.14"
    }
  }
  </code></pre>
  
  <p>I fixed it by including the below in my index but I don't understand why do I have to do this when I've required the bootstrap and jquery module already?</p>
  
  <pre><code>&lt;script src="./node_modules/jquery/dist/jquery.min.js"&gt;&lt;/script&gt;
  &lt;script type="text/javascript" src="bundle.js"&gt;&lt;/script&gt;
  </code></pre>
  
  <p>//webpack.config.js</p>
  
  <pre><code>module.exports = {
    context: __dirname,
    entry: "./api_assignment.jsx",
    output: {
      path: "./",
      filename: "bundle.js"
    },
    module: {
      loaders: [
        {
          test: /\.jsx?$/,
          exclude: /node_modules/,
          loader: 'babel',
          query: {
            presets: ['react']
          }
        }
      ]
    },
    devtool: 'source-map',
    resolve: {
      extensions: ["", ".js", ".jsx"]
    }
  };
  </code></pre>