CoffeeScript the Awesome

  • 1,277 views
Uploaded on

Coffee

Coffee

More in: Technology
  • Full Name Full Name Comment goes here.
    Are you sure you want to
    Your message goes here
    Be the first to comment
    Be the first to like this
No Downloads

Views

Total Views
1,277
On Slideshare
0
From Embeds
0
Number of Embeds
0

Actions

Shares
Downloads
21
Comments
0
Likes
0

Embeds 0

No embeds

Report content

Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
    No notes for slide
  • We’ve all seen the funny photos. JavaScript is rough around the edges, very rough
  • Incuding the existential operator
  • Incuding the existential operator
  • Incuding the existential operator

Transcript

  • 1.
  • 2. CoffeeScript
    The Awesome
  • 3. “A Propos de Moi”
    @kouphax
    http://yobriefca.se
    http://github.com/kouphax
  • 4.
  • 5. A Few CoffeeScript Facts
    Created by Jeremy Ashkenas circa late 2009
    Spawned from reading “Create Your Own Programming Language”
    CoffeeScript compiles to, and executes as, JavaScript in the browser.
    CoffeeScript simply offers an initial compilation step prior to the JavaScript being interpreted – what's the harm in that?
    CoffeeScript does not require you to abandon all your JS libraries
    Yes you can still use jQuery or anything else you want
    JavaScript produced by the CoffeeScript compiler is performant, valid and well formatted.
  • 6. Debugging CoffeeScript directly is currently not possible so this adds another layer of complexity
    In reality mapping between CoffeeScript and the generated JavaScript isn’t difficult
    Could be considered just syntactical sugar with some extra syntax benefits
    No more random semi-colon insertion
    No more accidental global scoping of declarations
    Scoping syntax built right in
    Automatic “hoisting” of variable declarations
    Not everyone is a massive fan
    A Few (More) CoffeeScript Facts
  • 7.
  • 8. Range Compreshension
    English Notation
    Variable Declaration
    Function Declaration
    String Interpolation
    Function Call
    Loop Comprehension
    * Never do this in real life kthanxai
  • 9.
  • 10. CoffeeScript: A Guided Tour
    - or -
    CoffeeScript: A Guided Tour of the Website, Pretty Much, Except in Slide Form but Not Because I am Lazy, No, More so Because It’s a Fairly Comprehensive Document of the Features of CoffeeScript.
  • 11. Functions
  • 12. Functions
  • 13. Objects
  • 14. Conditionals
  • 15. Operators and Aliases
  • 16. Splats
  • 17. Loops and Comprehensions
  • 18. Array Slicing and Ranges
  • 19. Classes
  • 20. Odds and Ends
  • 21. Using CoffeeScript in .NET
    - or -
    What? You think we’d let those script kiddies have all the fun? Hells no!
  • 22. Compile On Demand
    Shameless Plug
    (but I am distracting you through the use of Comic Sans)
    …and others
  • 23. Pre-compile
  • 24.
  • 25. Questions?