Code Format Help

Answered

After updating intelliJ IDEA the built in code format tool (shift opt cmd L) no longer formats code correctly

This
```
import { Typography } from "@mui/material";

const Home = () => {
    return (
        <Typography variant="h1" align="center" color="primary">
            Home
        </Typography>
    );
};

export default Home;
```
becomes
```
import { Typography } from

"@mui/material";

const Home = () => {
    return ( < Typography
    variant = "h1"
    align = "center"
    color = "primary" > Home < /Typography>
)
    
};

export default Home;

```

 

after dabbling for a few hours trying to correct this within my style settings I have given up. No new plugins have been installed.

All help is greatly appreciated

1
1 comment

Unfortunately I failed to reproduce the issue

Could you share a complete code snippet that reproduces it plus your code style preferences (<IDE config dir>/codestyles/<scheme name>.xml) if you are using IDE-level scheme, or .idea\codeStyles\Project.xml when using a project scheme)?

0

Please sign in to leave a comment.