Fixing: “ESLint: Expected indentation of 2 spaces but found 6. (indent)” in PhpStorm
To fix the issue, go to File > Settings > Editor > Code Style > HTML > Other , and for “Do not indent children of” add the “script” tag to the list. That’s it! You can try re-formatting your code now, and the code indentation in the script tag should be gone now, as well as the ESLint warning. Happy coding!