I\'m trying to setup a new project in Visual Studio that is going to be MVC 5 with a single page app written in ReactJS. So I followed the guide on the ReactJS website.
I figured it out - the tutorial is missing two things:
The script inclusion should be done thus, with a type declaration:
The JSX transformer needs to be included:
So the full HTML output by the Razor view should look like this:
Hello React
Looks like they need to update their tutorial.
Update:
Commenter @DanielLoNigro added this helpful tip:
Actually if you're using ReactJS.NET, you don't need to use the client-side JSXTransformer. Just ensure that the JSX handler is configured in your Web.config file (there should be a handler for .jsx).