title: Webpack/React.js: You may need an additional loader to handle the result of these loaders
body: <blockquote>
    <p>ERROR in ./productFlow/index.tsx 3:12 Module parse failed: Unexpected
    token (3:12) File was processed with these loaders:  *
    ./node_modules/awesome-typescript-loader/dist/entry.js You may need an
    additional loader to handle the result of these loaders. | import
    React from 'react'; | export default props => {
       return ( |       <code>&lt;p&gt;Compiled Successfully&lt;/p&gt;</code> |     );</p>
  </blockquote>
  
  <p>It appears to fail when it hits JSX code (in a .tsx file). Is at-loader not capable of handling this? I searched around for a react loader but the examples I saw were closer to my own:</p>
  
  <pre><code>const webpack = require("webpack");
  const dotEnvWebpack = require("dotenv-webpack");
  const path = require("path");
  
  const webpackConfiguration = {
    entry : {
      productFlow : path.join(__dirname, "productFlow/index.tsx")
      , registrationFlow : path.join(__dirname, 'registrationFlow/index.tsx')
    }
    , output : {
      filename : "outputFiles/[name].output.js"
      , path : path.resolve(__dirname, "")
      , publicPath : '/'
    }
    , watch : true
    , watchOptions : { aggregateTimeout : 300 }
    , devtool : 'inline-source-map'
    , mode : "development"
    , devServer : {
      port: 3000
      , contentBase : path.join(__dirname, "devIndex.html")
      , hot : true
      , historyApiFallback : true
    }
    , plugins : [
      new webpack.HotModuleReplacementPlugin(),
      new dotEnvWebpack
    ]
    , node : {
      fs: "empty" // for dotenv to work correctly
    }
    , resolve : { extensions : ['.ts', '.tsx', '.js'] }
    , module : {
        rules : [{
          test : /\.tsx?$/
          , use : 'awesome-typescript-loader'
          , exclude : [/node_modules/, /outputFiles/]
        }]
    }
    , externals : {
        'react' : 'React'
        , 'react-dom' : 'ReactDOM'
    }
  };
  
  module.exports = webpackConfiguration;
  
  </code></pre>