CoffeeScript

CoffeeScript是一种编译成JavaScript的小语言。(CoffeeScript is a little language that compiles into JavaScript. )

Github stars Tracking Chart

CoffeeScript是一种编译成JavaScript的小语言。在这个尴尬的Java风格的光泽下面,JavaScript一直有一个华丽的心。 CoffeeScript是一种尝试以简单的方式公开JavaScript的好处。

CoffeeScript的黄金法则是:“只是JavaScript”。 代码将一对一编译成等效的JS,并且在运行时没有解释。 您可以使用CoffeeScript中任何现有的JavaScript库(反之亦然)。 编译的输出是可读的,漂亮的打印,并且倾向于比等效的手写JavaScript快或快。
CoffeeScript编译器非常愿意在每个JavaScript运行时生成输出JavaScript,但也有例外。 只有当您知道目标运行时可以支持它们时,才能使用生成器函数,用于...或者标记的模板文字。 如果您使用模块,则需要使用其他工具来解决这些问题。

Overview

Name With Ownerjashkenas/coffeescript
Primary LanguageCoffeeScript
Program languageCoffeeScript (Language Count: 2)
PlatformLinux, Mac, Windows
License:MIT License
Release Count101
Last Release Name2.7.0 (Posted on )
First Release Name0.1.0 (Posted on )
Created At2009-12-18 01:39:53
Pushed At2024-03-22 14:04:00
Last Commit At
Stargazers Count16.4k
Watchers Count513
Fork Count2k
Commits Count4.9k
Has Issues Enabled
Issues Count4150
Issue Open Count68
Pull Requests Count882
Pull Requests Open Count14
Pull Requests Close Count347
Has Wiki Enabled
Is Archived
Is Fork
Is Locked
Is Mirror
Is Private
      @@@@@@@                @@@@  @@@@@
     @@@@@@@@@@              @@@   @@@                                           {
    @@@@     @@              @@@   @@@                                        }   }   {
   @@@@          @@@@@@@    @@@   @@@     @@@@@@    @@@@@@                   {   {  }  }
  @@@@          @@@   @@  @@@@@  @@@@@@  @@@   @@  @@@@  @@                   }   }{  {
  @@@@         @@@@   @@   @@@    @@@   @@@   @@@ @@@   @@@                  {  }{  }  }
  @@@@        @@@@    @@   @@@    @@@   @@@@@@@@  @@@@@@@@                  { }{ }{  { }
  @@@@@       @@@@   @@    @@@    @@@   @@@       @@@                     {  { } { } { }  }
   @@@@@@@@@@ @@@@@@@@    @@@    @@@    @@@@@@@@  @@@@@@@@                 { }   { }   { }
      @@@@@               @@@    @@@      @@@@@     @@@@@           @@@@@@   { }   { }    @@@@@@@
                         @@@    @@@                                 @@@@@@@@@@@@@@@@@@@@@@@@@@@@
      @@@@@@            @@@    @@@                                @@ @@@@@@@@@@@@@@@@@@@@@@@@@@
   @@@@    @@          @@@   @@@@                                @@   @@@@@@@@@@@@@@@@@@@@@@@@
   @@@@   @@@                       @@                  @@@@     @@@   @@@@@@@@@@@@@@@@@@@@@
   @@@@@          @@@@@   @@  @@   @@@     @@@@@@@     @@@@@      @@@    @@@@@@@@@@@@@@@@@@
     @@@@@      @@@  @@@ @@@@@@@@         @@@@  @@@@  @@@@@@@       @@@   @@@@@@@@@@@@@@@@
       @@@@@   @@@       @@@@     @@@@    @@@    @@@   @@@                 @@@@@@@@@@@@@@
 @@@@@  @@@@  @@@@      @@@@      @@@@   @@@@   @@@@  @@@@
@@@     @@@@  @@@       @@@@     @@@@    @@@    @@@@  @@@@
@@@     @@@@  @@@@     @@@@      @@@@   @@@@   @@@@  @@@@
 @@@@@@@@@     @@@@@@  @@@@       @@@@  @@@@@@@@@    @@@@
                                       @@@          @@@@
                                      @@@
                                      @@@

CoffeeScript is a little language that compiles into JavaScript.

Installation

Once you have Node.js installed:

# Install locally for a project:
npm install --save-dev coffeescript

# Install globally to execute .coffee files anywhere:
npm install --global coffeescript

Getting Started

Execute a script:

coffee /path/to/script.coffee

Compile a script:

coffee -c /path/to/script.coffee

For documentation, usage, and examples, see: https://coffeescript.org/

To suggest a feature or report a bug: https://github.com/jashkenas/coffeescript/issues

If you’d like to chat, drop by #coffeescript on Freenode IRC.

The source repository: https://github.com/jashkenas/coffeescript.git

Changelog: https://coffeescript.org/#changelog

Our lovely and talented contributors are listed here: https://github.com/jashkenas/coffeescript/contributors

To the top