instance = current}/>
);
```
### β
Example of correct code
```jsx
function App() {
const [theme, setTheme] = useState('light');
// ...
return (
);
}
```
## rename-file-js-to-jsx
Rename `*.js` files to `*.jsx` when they contains JSX.
```diff
/
|-- package.json
`-- lib/
- `-- hello.js
+ `-- hello.jsx
```
Check out in π[Putout Editor](https://putout.cloudcmd.io/#/gist/bebaba6a03958effd72f160f9ef8c8ef/e3a275a2d6352183f71415dcd4346f2cd5667748).
## rename-file-jsx-to-js
Rename `*.jsx` files to `*.js` when they contains JSX.
```diff
/
|-- package.json
`-- lib/
- `-- hello.jsx
+ `-- hello.js
```
Check out in π[Putout Editor](https://putout.cloudcmd.io/#/gist/20bb4c5e3646ebbebccdc23bc93224c1/a0216b8fce6dce41fce16534d80354d9d94c6983).
### β Example of incorrect code
```jsx
const a = (
instance = current}/>
);
```
### β
Example of correct code
```jsx
function App() {
const [theme, setTheme] = useState('light');
// ...
return (
);
}
```
### apply-jsx-to-imported-file
Checkout in π**Putout Editor**:
- β
[`get-imports`](https://putout.cloudcmd.io/#/gist/ee10100fed86e4db926885dd54298668/7538bca7a9ae006d976f41261c0ed4c0e1902ace);
- β
[`change-imports`](https://putout.cloudcmd.io/#/gist/23a6dc6741b772c03fbed95feda2b451/1fbecac6fc40282bcda0593aa666a8c213ef85b7);
Let's consider file structure:
```
/
βββ lib/
βββ index.js
βββ a.jsx
```
In this case `index.js` can be fixed:
#### β Example of incorrect code
```js
import a from './a.js';
```
#### β
Example of correct code
```js
import a from './a.jsx';
```
### convert-named-to-default-in-react-test-renderer
Checkout in π[**Putout Editor**](https://putout.cloudcmd.io/#/gist/332db6dc617574d18ac6e10e1e2a77c9/2e4e30d0a6a8539b0c994315773b0d1a45b286f7).
#### β Example of incorrect code
```js
import {createRenderer} from 'react-test-renderer/shallow';
```
#### β
Example of correct code
```js
import reactTestRenderer from 'react-test-renderer/shallow.js';
const {createRenderer} = reactTestRenderer;
```
## License
MIT