Accepted answer

You need to use the render function correctly:

    Hello react!

(Instead of render { ... })


I think you're missing the Babel configuration, either in webpack (in the loaders section) or the .babelrc file itself. You need to tell Babel to process your code and apply the react preset.

If you post your webpack.config.js and .babelrc we'll be able to point the specific missing part.

Otherwise you may want to take a look into the create-react-app package which is a great and official way to kickstart a React app.

Related Query

More Query from same tag