Do all the things like ++ or -- rants, post your own rants, comment on others' rants and build your customized dev avatarSign Up
From the creators of devRant, Pipeless lets you power real-time personalized recommendations and activity feeds using a simple APILearn More
Thats.... totaly random, and makes no sense!
my team should adopt!
sebson583yWe have similar in regard to sorting imports. As a junior Dev found that so frustrating but then discovered everyone used a plug-in for that, but didn't tell me 🤣
@sebson FYI that is a VERY stupid idea. Not only it does not add anything useful to the code, it also
a) wastes your time on (re)arranging things
b) shuffles imports from different packages, hence if you ever need to see how dependent you are on some packages you will have an obfuscated imports' list to unshuffle.
This approach does only one thing well. Wastes everyone's time
Please explain "fir-like blocks of code". I searched for it, but could not find anything related to coding. Does it literally look like a fir tree?
Okay, I re-read it. It is about the imports at the beginning of the file. It should look sloping down to the right. Yeah, that is fucking stupid! Imports should be divided up by relevance/function if anything. Not making some picture in code. Okay, you win devrant this week! This is the ultimate.
@Demolishun Not just imports.. Anything that does not care about ordering.
Protected variables' declarations (code style did not allow anything private)
Method variables' declarations
Hence the fir-like code :) Slope goes down-right, then code happens, then again goes down-right, etc.
There were other code-style decisions that made me explode inside, but the fir-like code was the cherry on a top
Parzi91233yi'd sort every line alphabetically and by length (yes, EVERY LINE) then do a PR just to protest.
Quirinus7933yLol what, you have to sort methods by length? Bahaahah
Thats some next level stupidity
Omnisus4173yParse each line to put chars in alphabetical order, it will look more esthetically pleasing 😃
@sebson I'm always stressed about where I should add my import statement in the mess of imports
caap3913yIt's not that uncommon, I guess. But usually your company should provide a preconfigured IDE then..
@caap seriously..? Why do people do that...?
No, listen to me. I cannot approve this PR because your code does not comply with our code style. All the imports and annotations must be sorted in ascending order by length. They must all make fir-like blocks of code. Because it looks nice.
Now go and fix your code
I just smiled and walked away to obfuscate my code with firs . I had no idea what to even say to that... I still don't