Skip to content

Conversation

unkarjedy
Copy link
Contributor

There might be a more general issue with the .md files rendered used on the site.
It incorrectly handles indentation.
It removes indentation from the first line, but leaves remaining lines untouched.
IMO it shouldn't affect indentation at all, and all existing code blocks should be reviewed and the indentation should be removed.

Example of bad rendering:
image
image
image

@dwijnand
Copy link
Member

@Florian3k can you see if we can address the root cause? We shouldn't remove the indentation on the first line.

@Florian3k
Copy link
Contributor

Florian3k commented Sep 25, 2023

Yes, that's definitely something to fix (created #18593 for this).

Another issue is that we have different indentation in code blocks throughout the documentation (sometimes none, sometimes whole snippet is indented by 2 spaces). Do we want to unify this, and if so which way?

@unkarjedy
Copy link
Contributor Author

IMO it shouldn't affect indentation at all, and all existing code blocks should be reviewed and the indentation should be removed.
Florian3k can you see if we can address the root cause? We shouldn't remove the indentation on the first line.

And if it's fixed, ideally all pages should be reviewed for code examples with common indentation.
I noticed that one ^ by accident.
Some regexp-search for the first line could be used.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

3 participants