This repository has been archived on 2024-10-22. You can view files and clone it, but cannot push or open issues or pull requests.
spacemacs/layers/+lang/coffeescript/README.org

56 lines
1.7 KiB
Org Mode
Raw Normal View History

#+TITLE: CoffeeScript layer
#+TAGS: general|js|layer|multi-paradigm|programming
2019-05-05 17:26:40 +00:00
[[file:img/coffee.png]]
2019-05-07 20:05:06 +00:00
* Table of Contents :TOC_5_gh:noexport:
- [[#description][Description]]
- [[#features][Features:]]
- [[#install][Install]]
- [[#configuration][Configuration]]
- [[#linting][Linting]]
- [[#key-bindings][Key bindings]]
- [[#repl][REPL]]
* Description
This layer adds support for the CoffeeScript language using [[https://github.com/defunkt/coffee-mode][coffee-mode]].
** Features:
- Syntax highlighting
- Auto-completion with =auto-completion= layer
- Syntax checking and linting with =syntax-checking= layer
- =Org-Babel= integration
- REPL support
* Install
To use this configuration layer, add it to your =~/.spacemacs=. You will need to
add =coffeescript= to the existing =dotspacemacs-configuration-layers= list in
this file.
* Configuration
** Linting
2019-01-13 18:09:06 +00:00
To enable linting, install [[https://github.com/clutchski/coffeelint][CoffeeLint]] with the following command:
#+BEGIN_SRC sh
2018-09-19 03:54:47 +00:00
npm install -g coffeelint
#+END_SRC
* Key bindings
| Key binding | Description |
2018-05-14 02:26:47 +00:00
|-------------+------------------------|
| ~SPC m c c~ | Compile buffer |
| ~SPC m c r~ | Compile region |
| ~SPC m T c~ | Toggle compile on save |
** REPL
| Key binding | Description |
|-------------+----------------------------------------------------|
| ~SPC m '~ | Create or go to REPL |
| ~SPC m s b~ | Send buffer to REPL |
| ~SPC m s i~ | Create or go to REPL |
| ~SPC m s l~ | Send line to REPL |
| ~SPC m s r~ | send current region to the REPL and stay in buffer |