I was trying to add a new .js file but forgot to add an extension. I removed it and created a new one but intelliJ won't recognize it as a JavaScript File.
What I've tried:
- Removing it and re-creating it
- Commit it to git
- Restarting IntelliJ
- Rebooting the computer
The file:
myComponent.js
import React from 'react';
const MyCOmponent = () => {
return <h1>Hello World!</h1>;
}
export default MyComponent;