You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This feels a bit like recast's bug to me. As I checked, we seems to be detecting them correctly and passing { useTabs: true, tabWidth: 1 }. And normally I think when useTabs is set, tabWidth should be ignored, but in real, it actually affects how many tabs are generated (passing 2 makes it generate fewer tabs somehow).
Could use some help if anyone wants to go deeper on it.
@antfu I assume tabWidth is a bit like the ts query parameter in github. If the indentation is 2 tabs in your code, and you set ?ts=2 in any GitHub URL, the 2 tabs will look like 4 spaces. Similarly if you do ?ts=4, 4 tabs will look like 4 spaces.
Hence I guess tabWidth: 1 tells the generator that to preserve the look of 4 spaces, insert 4 tabs there.
Environment
[email protected]
[email protected]
[email protected]
Reproduction
Describe the bug
In the reproduction above, the indentation of
plugins
is a single tab. However, the generated code uses four tabs.Additional context
Result:
Expected:
The text was updated successfully, but these errors were encountered: