-
Notifications
You must be signed in to change notification settings - Fork 1k
Add code tabs to Other changes page #2725
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hey Lucas, I started reviewing this but it seems you always put “Scala 3 Only” as a tab title for code that compiles with Scala 2 only. Or do I miss something?
Oh yes, that's a misunderstanding on my part. For me, since there was an error afterwards it was like saying that this code in scala 3 has the error right afterwards. So what I can do is put the code in scala 2 only and say that in scala 3 only it produces the error. |
That sounds good to me, thank you! |
Yeah, that is tricky, I understand your reasoning. By putting the “Scala 3 Only” you mean “that error that we mention in the code snippet happens in Scala 3 Only”. But everywhere else on the website we use “Scala 3 Only” to indicate a code snippet that is valid only in Scala 3. I think we could make things clearer with the following approach:
How does that sound? |
Oh yes, indeed, I think it is better in terms of understanding. Thank you for your attention. And so I put back all the {% highlight diff %}? I thought it was a difference between Scala 2 and Scala 3 so I put them in the tabs, but it is true that in terms of understanding it is good to have the difference with the -/+. Should I still put the {% highlight diff %} in the tabs of Scala 3 only (or others)? Like this example below : |
In that case, since we show a diff and not a code snippet that the readers than copy-paste, we can leave out the tab. |
Corrections of the tabs. - Change scala 3 only by scala 2 only - Re-add highlight parts Delete Darwin dependencies
6fece46
to
1433888
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you again Lucas for your help, but I’ve noticed a pattern that should be fixed: the tabs should primarily wrap code snippets, not text, unless the tabs contain different code snippets and we want to add some text specifically for each snippet.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you for adding all the code tabs!
Here is my PR to add code tabs to the Other changes page
Ref #2481