/me joining a new front-end project with enforced prettier rules to complete the build pipeline.

No double-quotes ! Single-quotes all the way !

- weird flex, but OK. I'll comply

No CRLF ! LF only !

- Ok, now you're starting to annoy me. With git autocrlf I can have my precious CR locally bu check in only LF and YOU CAN GIVE THE FUCK ABOUT WHAT LINE ENDINGS I USE LOCALLY WHEN EVERYTHING WILL BE CORRECT WHEN PUSHING COMMITS!

No semi-colons !

- Now I hate you

  • 8
    "no semi-colons" <- how to spot a retard. be it "defining code style rules" or "designing a language"
  • 0
    So no CR means each line keeps going to the right on each line feed? How wide is their screen? lol
  • 2
    So no ; ? That means no for loops with indexes?
  • 3
    @Demolishun import loop from 'for-loop'
  • 3
    @tosensei spend a few weeks with modern languages like Kotlin or Swift and you‘ll start to see semicolons as antiquated.

    IIRC, JS is a different story because they are pseudo-optional and can cause some obscure bugs when omitted. But I‘m not 100% sure about that.
  • 2
    No carriage return?!

    WTF! Don't they use teletype terminals for coding like everyone else?!
  • 1
    Haven’t you heard of auto formatting?
  • 0
    "No CRLF ! LF only !"

    This makes a lot of sense. I do not want CRLF in normal files. And don't activate some auto convertor, this should only be done explicit. What if there is a file that actually needs CRLF? Normal files should have LF only.
  • 0
    "No double-quotes ! Single-quotes all the way !"

    This also makes sense. In a language where this does not matter it is a good idea to have all quotes the same way. Using " in some places and ' in others without a rule where to use which one to use where is bad.

    "No semi-colons !"

    This also makes sense. I don't know about JavaScript but in bash people often use semi-colons to write an uglier style.
  • 0
    LF makes sense, rest is bit dubious in my opinion.

    When you know how to configure GIT, you're ahead of most devs...

    Yes, even Windows Devs where the installer asks for this behaviour....

    The end result is a clusterfuck. Mixed line endings can result in severe problems.
  • 0
    @tosensei what about a language that opens scopes with a colon and closes them with a semicolon?
    Basically replacing brackets?

    On a scale of 1 to 10 how retarded is that?
  • 0
    @happygimp0 something about double quotes always seemed more literal to me.

    Also how are you supposed to close strings and include apostrophes at the same time when you're only allowed single quotes?
  • 1
    @IntrusionCM I also think that LF makes sense, but in terms of everything else, don't you think that single quotes make sense in certain languages such as PHP? Performance wise (which ain't that big of a deal for what I am about to say) the interpreter does not have to do a check to see if something is to be interpolated, but at the same time, for non properly escaped user input in which something like $showMeYoTitties gets added by the user, then single quotes make more sense to me.

    Idk fam, just saying, really interested in your input for this
  • 0
    @CeladonCookie SHIFT+2 is faster and easier for the fingers to reach than ' next to backspace.

    That is really my only argument.
  • 0
    @IntrusionCM I know. I configured git to not convert LF to CRLF. Would prefer default, though
  • 2

    I would rate semicolon scoping at a solid over9000 of 10 on the retarded scale.
  • 1
    @AleCx04 Yes.

    But the thing with quoting is reason why I said dubious.

    In dubio pro reo.

    I don't like the argumentation of performance, cause especially in PHP or in the author's case of JS the argument is rather "shady". PHP has OpCaching for a reason and in JS the only reason JS works well is compiler and optimization, otherwise JS wouldn't be so popular.

    Hence eliminating that argument, I like the quoting style of single quotes more than double quotes - it's explicit.

    But it can backfire in unpleasant ways...

    "This is a string with $var \n"

    'This is a string with ' . $var . "\n"

    In most cases, single quotes only requires usage of sprintf or mixing of double quotes and single quotes.

    You want stuff to be interpreted sometimes.

    Which is way I say dubious - a strict requirement as in MUST not use double quotes is in my opinion braindamaged.

    What would be more sensible would be: SHOULD use single quotes if applicable.

    Entirely different meaning
  • 0
    @IntrusionCM makes sense to me
Add Comment