The Little Book on CoffeeScript 9781449325541, 1449325548, 9781449325558, 1449325556

This little book shows JavaScript developers how to build superb web applications with CoffeeScript, the remarkable litt

381 16 2MB

English Pages 60 Year 2012

Report DMCA / Copyright

DOWNLOAD FILE

The Little Book on CoffeeScript
 9781449325541, 1449325548, 9781449325558, 1449325556

Table of contents :
Content: Table of Contents
Preface
What Is CoffeeScript?
Initial Setup
Conventions Used in This Book
Using Code Examples
Safari® Books Online
How to Contact Us
Chapter 1. CoffeeScript Syntax
Variables and Scope
Functions
Function Arguments
Function Invocation
Function Context
Object Literals and Array Definition
Flow Control
String Interpolation
Loops and Comprehensions
Arrays
Aliases and the Existential Operator
Chapter 2. CoffeeScript Classes
Instance Properties
Static Properties
Inheritance and Super
Mixins
Extending Classes
Chapter 3. CoffeeScript Idioms
Each
Map. SelectIncludes
Property Iteration
Min/Max
Multiple Arguments
And/Or
Destructuring Assignments
External Libraries
Private Variables
Chapter 4. Compiling CoffeeScript
Cake
Creating Applications
Structure and CommonJS
Requiring files
Exporting properties
Stitch It Up
JavaScript Templates
Bonus: 30-Second Deployment with Heroku
Additional Libraries
Chapter 5. The Good Parts
The Unfixed parts
Using eval
Using typeof
Using instanceof
Using delete
Using parseInt
Strict Mode
Strict Mode Changes
Strict Mode Usage
The Fixed Parts
A JavaScript Subset
Global Variables. SemicolonsReserved Words
Equality Comparisons
Function Definition
Number Property Lookups
JavaScript Lint
Chapter 6. The Little Conclusion
Philosophy
It's Just JavaScript
Build Your Own JavaScript.

Polecaj historie