The main purpose of CoffeeScript is –
ü Write simple and better code
ü More relevant syntax and
ü Avoiding the irregular nature of JavaScript code
CoffeeScript is an attempt to expose the good parts of JavaScript in a simple way.
CoffeeScript was designed and developed by Jeremy Ashkenas in Dec, 2009.
Jeremy Ashkenas was inspired by Python, Ruby and Haskell and it adopted syntax and coding styles from them which makes it very useful and unique.
1. Filename extensions- coffee, .litcoffee
2. First appeared- Dec 13, 2009
3. Stable release- 2.0.0 / Sep 18, 2017
4. Designed by- Jeremy Ashkenas
5. Influenced by- Haskell, JavaScript, Perl, Python, Ruby, YAML
6. License- MIT License
The CoffeeScript Latest Version is - 2.2.2
1. Install locally for a project - npm install --save-dev coffeescript
2. Install globally to execute .coffee files - npm install --global coffeescript
Basic rules to remember for CoffeeScript -
The Rules for CoffeeScript is -
1. Whitespace matters
2. No parentheses
Advantages of CoffeeScript -
1. Lots of less code with CoffeeScript rather than JavaScript.
2. Easier to perform with CoffeScript rather than JavaScript
3. Contains lightweight add-ons.
Disadvantages of CoffeeScript -
1. CoffeeScript includes an additional compilation step while compilation - compiles into JavaScript
2. Only limited resources are available for CoffeeScript.
0 comments:
Post a Comment