I am using a separate javascript file to put my React JS JSX in. When I use the example given by the documents, I get tons of Visual Studio warnings and ugly squiggly lines..
I cannot figure out a way around this.. Pretty much a deal breaker for React JS.
You use ${} in string templates like const k = `my name is ${name}` you use {} whenever you want to put some Java code in your JSX code like <div attr={name}>{name}</div>
Go to settings > extensions > emmet > include languages and add javascript as the item and javascriptreact as the value.
It is called JSX, and it is a syntax extension to JavaScript. We recommend using it with React to describe what the UI should look like. JSX may remind you of a template language, but it comes with the full power of JavaScript. JSX produces React “elements”.
Visual Studio 2012 was released before ReactJs, so you can't really blame them for not supporting it.
There is some visual studio stuff here:
http://reactjs.net/
You can see support for tooling being asked here:
https://github.com/reactjs/React.NET/issues/3
with Web Essentials being one of the prime picks for asking for support (might want to add your votes!)
If you are using Resharper it might be added in the next release, JetBrains is looking to add it into WebStorm
https://youtrack.jetbrains.com/issue/WEB-10136
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With