Created
October 12, 2011 17:08
-
-
Save rehanift/1281845 to your computer and use it in GitHub Desktop.
How to get js2-additional-externs working with js2-mode
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(defun rli-add-jasmine-externs() | |
(when (string-match "_spec.js" (buffer-file-name)) | |
(setq js2-additional-externs | |
'("jasmine" "describe" "xdescribe" "it" "xit" "expect" "spyOn" | |
"beforeEach" "afterEach" "runs" "waits" "waitsFor"))) | |
) | |
(add-hook 'js2-mode-hook 'rli-add-jasmine-externs) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment