I have become quite attracted to CoffeScript lately and I can see how this blog post could discourage some to avoid it, but actually it just made me like it more..!
Seeing as this is a deliberate design choice from the creator, there must be a reason why it's made this way and why so many people use it.. So one little blog post isn't going to scare me that easily..
The more I think about it and read the comments in this thread, the more it makes me understand what makes CS so special.. how it encourages simple and beautiful code by thinking about how you name things.. and not just be some punch card like stream of verbose mechanical instructions..
An easy and natural way of avoiding accidental shadowing is to group and structure all your code and variables into objects and classes; make your program modular.. that way the global scope won't be cluttered with all kinds of confusing names.. you would only have a limited number of modules who can access each other through each respective namespace.. clear and simple..
Every good developer knows that each tool/language serves different use cases and different people.. hopefully this thread will help you decide better whether CS is something for you.. if not, there are plenty of other languages to go around.. :)
trust your technolust.. :D
EDIT: I guess what I'm trying to say is that I understand how this scoping would fit well with CoffeeScript's personality, but I also understand why the blogger consideres this dangerous behavior, because it really is.. But that's CoffeeScript for you.. take it or leave it..
Seeing as this is a deliberate design choice from the creator, there must be a reason why it's made this way and why so many people use it.. So one little blog post isn't going to scare me that easily..
View all comments
-5
u/[deleted] Jul 26 '13 edited Jul 26 '13
I have become quite attracted to CoffeScript lately and I can see how this blog post could discourage some to avoid it, but actually it just made me like it more..!
Seeing as this is a deliberate design choice from the creator, there must be a reason why it's made this way and why so many people use it.. So one little blog post isn't going to scare me that easily..
The more I think about it and read the comments in this thread, the more it makes me understand what makes CS so special.. how it encourages simple and beautiful code by thinking about how you name things.. and not just be some punch card like stream of verbose mechanical instructions..
An easy and natural way of avoiding accidental shadowing is to group and structure all your code and variables into objects and classes; make your program modular.. that way the global scope won't be cluttered with all kinds of confusing names.. you would only have a limited number of modules who can access each other through each respective namespace.. clear and simple..
Every good developer knows that each tool/language serves different use cases and different people.. hopefully this thread will help you decide better whether CS is something for you.. if not, there are plenty of other languages to go around.. :)
trust your technolust.. :D
EDIT: I guess what I'm trying to say is that I understand how this scoping would fit well with CoffeeScript's personality, but I also understand why the blogger consideres this dangerous behavior, because it really is.. But that's CoffeeScript for you.. take it or leave it..