phptools-docs
phptools-docs copied to clipboard
Wrong indentation after formatting [ continuation of issue #173 ]
[ continuation of #173 ], as @Miloslav mentioned:
Yes, please feel free to open a github issue for that one - just to make sure, it's the same as we have internally
The current state of the issue after fresh testing:
Code before formatting:
<h2 class="hello"><a class="text" href="<?php strtolower('TIME'); ?>"><?php time(); ?></a></h2>
Code after formatting:
<h2 class="hello"><a class="text" href="<?php strtolower('TIME'); ?>">
<?php time(); ?>
</a></h2>
Description:
This happens the first time you use formatting
Env
- OS Name: Microsoft Windows 11 Pro
- OS Version: 10.0.22621 N/A Build 22621
VSCode
Version: 1.74.2
Commit: e8a3071ea4344d9d48ef8a4df2c097372b0c5161
Date: 2022-12-20T10:29:14.590Z
Electron: 19.1.8
Chromium: 102.0.5005.167
Node.js: 16.14.2
V8: 10.2.154.15-electron.0
OS: Windows_NT x64 10.0.22621
Sandboxed: No
VSCode settings
{
"php.suggest.basic": false,
"php.validate.enable": false,
"emmet.excludeLanguages": [
"markdown",
"php"
],
"php.problems.exclude": {
"vendor/": true,
},
"php.codeLens.enabled": false,
"html.format.wrapLineLength": 0
}
Do you have any additional add-ons besides DEVSENSE?
- No
It appears to be a weird behavior of the default vscode HTML formatter.
If you create an HTML file and format this thing:
<h2><a href=""><p>Text</p></a></h2>
Looks like you're right, let's see what they say ---> https://github.com/microsoft/vscode/issues/170509