2015-12-02 14:23:39 +00:00
|
|
|
#+TITLE: TypeScript layer
|
2015-11-08 18:04:44 +00:00
|
|
|
#+HTML_HEAD_EXTRA: <link rel="stylesheet" type="text/css" href="../../../css/readtheorg.css" />
|
2015-06-10 16:44:30 +00:00
|
|
|
|
|
|
|
[[file:img/TypeScript.png]]
|
|
|
|
|
2015-10-30 11:20:58 +00:00
|
|
|
* Table of Contents :TOC_4_org:noexport:
|
|
|
|
- [[Description][Description]]
|
|
|
|
- [[Install][Install]]
|
|
|
|
- [[Layer][Layer]]
|
|
|
|
- [[Prerequisites][Prerequisites]]
|
|
|
|
- [[Key bindings][Key bindings]]
|
2015-06-10 16:44:30 +00:00
|
|
|
|
|
|
|
* Description
|
|
|
|
|
|
|
|
This layer adds support for TypeScript editing via [[https://github.com/clausreinke/typescript-tools][typescript-tools]] and
|
|
|
|
[[https://github.com/aki2o/emacs-tss][emacs-tss]].
|
|
|
|
|
|
|
|
This layer provides:
|
|
|
|
- syntax coloring
|
|
|
|
- error highlighting
|
|
|
|
- auto-completion via Flymake
|
|
|
|
- jump-to-definition
|
|
|
|
|
|
|
|
* Install
|
|
|
|
|
|
|
|
** Layer
|
|
|
|
|
|
|
|
To use this contribution add it to your =~/.spacemacs=
|
|
|
|
|
|
|
|
#+BEGIN_SRC emacs-lisp
|
|
|
|
(setq-default dotspacemacs-configuration-layers '(typescript))
|
|
|
|
#+END_SRC
|
|
|
|
|
|
|
|
** Prerequisites
|
|
|
|
|
|
|
|
You'll need [[https://github.com/clausreinke/typescript-tools][typescript-tools]] and fairly obviously also the TypeScript
|
|
|
|
compiler:
|
|
|
|
|
|
|
|
#+BEGIN_SRC sh
|
|
|
|
$ npm install typescript
|
|
|
|
$ git clone git://github.com/clausreinke/typescript-tools.git
|
|
|
|
$ cd typescript-tools/
|
|
|
|
$ npm install -g
|
|
|
|
#+END_SRC
|
|
|
|
|
|
|
|
* Key bindings
|
|
|
|
|
2015-06-12 01:23:07 +00:00
|
|
|
| Key Binding | Description |
|
|
|
|
|-------------+----------------------------------|
|
|
|
|
| ~SPC m g g~ | Jump to definition |
|
|
|
|
| ~SPC m h h~ | Show popup help (with type info) |
|