Visual Studio Code:[js] types can only be used in a .ts file : <p>Is it possible to use .js files in a typescript project in vs code? I have clone a react-native project from a github repository and opened it in visual studio code. When I add a tsconfig.json in order to start using typescript,
I get a long list of errors. For example here is a <strong>drawer.js</strong> file (with es6 features):</p>

<p><a href="https://i.stack.imgur.com/RpEfG.png" rel="noreferrer"><img src="https://i.stack.imgur.com/RpEfG.png" alt="enter image description here"></a></p>

<p>Here is my tsconfig.json file (If I remove this file then every thing works fine, no error reported) :</p>

<p><a href="https://i.stack.imgur.com/c8s23.png" rel="noreferrer"><img src="https://i.stack.imgur.com/c8s23.png" alt="enter image description here"></a></p>
