Earlier quoted context omitted.
I would agree that the indentation in CoffeeScript causes confusion, especially since the recommended size is 2 spaces.
I don't think indentation is a problem particularly. Once you're familiar with languages that use it, e.g. Python, it gets pretty natural. I did run into problems with the 2 space indentation, however, because with certain character combinations, it's difficult without a second look to be sure. I would argue there are bigger problems with CoffeeScript, such as empty blocks being legal. For example: if foo bar() Is to…
CoffeeScript's Time is Waning For Me
31–40 of 67 posts
Re: CoffeeScript's Time is Waning For Me
#32Earlier quoted context omitted.
I don't think indentation is a problem particularly. Once you're familiar with languages that use it, e.g. Python, it gets pretty natural. I did run into problems with the 2 space indentation, however, because with certain character combinations, it's difficult without a second look to be sure. I would argue there are bigger problems with CoffeeScript, such as empty blocks being legal. For example: if foo bar() Is to…
That's not legal in CoffeeScript either. I just tried it on the CS website and got the message "ERROR ON LINE 1: UNEXPECTED POST_IF".
Re: CoffeeScript's Time is Waning For Me
#33"As my project grows in size, significant whitespace becomes more and more of a problem. It’s just plain not readable or visually parsable. Your files become a wall of dense text. Damn you Python, damn you to hell!" I would appreciate an explanation of this paragraph. How exactly does project size compound issues with significant whitespace? Are you indenting five levels or something?
I would agree that the indentation in CoffeeScript causes confusion, especially since the recommended size is 2 spaces.
Re: CoffeeScript's Time is Waning For Me
#34"As my project grows in size, significant whitespace becomes more and more of a problem. It’s just plain not readable or visually parsable. Your files become a wall of dense text. Damn you Python, damn you to hell!" I would appreciate an explanation of this paragraph. How exactly does project size compound issues with significant whitespace? Are you indenting five levels or something?
I did find that odd. Whitespace helps you get away from "a wall of dense text." I'm not clear on how mandatory whitespace could exacerbate the "wall of dense text" problem. Does the author want to skip the indentation some of the time? I can think of a few marginal cases where that would be preferable. But in the vast majority of cases, you should indent any nested structure that has its own line(s). Indentation is e…
Coffeescript and significant whitespace eschew delimiters for indentation and other gimmicks, and the end result is something that is more difficult to read.
I totally agree with the author on this fact. I only see a "wall of dense text" when I read coffeescript, and when I read Javascript it is much easier to parse.
Re: CoffeeScript's Time is Waning For Me
#35"As my project grows in size, significant whitespace becomes more and more of a problem. It’s just plain not readable or visually parsable. Your files become a wall of dense text. Damn you Python, damn you to hell!" I would appreciate an explanation of this paragraph. How exactly does project size compound issues with significant whitespace? Are you indenting five levels or something?
Anyone who has maintained Makefiles will have a strong opinion on semantic whitespace. Maybe not opinion , but reaction . Generally involving visceral fear or anger. It's not that it's always bad, every hour of every day. It's that one time, at 1am, when you shouldn't be working but you are, something doesn't behave properly, and it turns out Bob the Intern re-indented a block of code to use tabs instead of spaces[1]…
Re: CoffeeScript's Time is Waning For Me
#36First of all if you want anyone else to help you with your code its likely that they don't know the wrapper's syntax and will have to waste a bunch of time learning it. My boss got super excited about it when it first came out and it just caused a lot of headache and wasted time. First I (and all my coworkers) had to learn the language, and then port all of our existing code to CoffeScript. And for what? Some syntax sugar?
Honestly, I don't really see any problems with Javascript's syntax. It's everything else.
Re: CoffeeScript's Time is Waning For Me
#37> If you’re contributing to the JS community, you’re better off writing in JavaScript. More people will contribute and/or adopt your code. Quality, not quantity. Maybe the higher quality contributors are more likely to get excited about a cs project over js.
That would be true if there wasn't a very vocal swath of developers that won't even use a CS project out of prejudice, much less contribute to it. I don't know why that religious war came to exist, but it's the unfortunate reality.
Re: CoffeeScript's Time is Waning For Me
#38"As my project grows in size, significant whitespace becomes more and more of a problem. It’s just plain not readable or visually parsable. Your files become a wall of dense text. Damn you Python, damn you to hell!" I would appreciate an explanation of this paragraph. How exactly does project size compound issues with significant whitespace? Are you indenting five levels or something?
Anyone who has maintained Makefiles will have a strong opinion on semantic whitespace. Maybe not opinion , but reaction . Generally involving visceral fear or anger. It's not that it's always bad, every hour of every day. It's that one time, at 1am, when you shouldn't be working but you are, something doesn't behave properly, and it turns out Bob the Intern re-indented a block of code to use tabs instead of spaces[1]…
Re: CoffeeScript's Time is Waning For Me
#39Earlier quoted context omitted.
I'm the author of the blog post. Significant whitespace is pretty dividing, and really boils down to preference. I have a strong dislike for it, and have avoided any language with it, CoffeeScript being the only exception. Here is a typical snippet of my code as seen in my editor: http://i.imgur.com/2yVhgcz.png IMO, those four methods really bleed together and are hard to discern, not to mention the if statements. I…
Try removing the indentation guides or decreasing their contrast so that they are just barely visible. They appear to cause strong visual grouping between code blocks and make it harder to see what's what.
Re: CoffeeScript's Time is Waning For Me
#40"As my project grows in size, significant whitespace becomes more and more of a problem. It’s just plain not readable or visually parsable. Your files become a wall of dense text. Damn you Python, damn you to hell!" I would appreciate an explanation of this paragraph. How exactly does project size compound issues with significant whitespace? Are you indenting five levels or something?
Anyone who has maintained Makefiles will have a strong opinion on semantic whitespace. Maybe not opinion , but reaction . Generally involving visceral fear or anger. It's not that it's always bad, every hour of every day. It's that one time, at 1am, when you shouldn't be working but you are, something doesn't behave properly, and it turns out Bob the Intern re-indented a block of code to use tabs instead of spaces[1]…