Skip to content

Commit

Permalink
Fix for ambiguous doc.
Browse files Browse the repository at this point in the history
  • Loading branch information
phtrivier committed Jan 16, 2014
1 parent cf78047 commit f9c887a
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,10 +37,16 @@ Add the following to your emacs init file.
(require 'web-beautify) ;; Not necessary if using ELPA package
(eval-after-load 'js2-mode
'(define-key js2-mode-map (kbd "C-c b") 'web-beautify-js))
;; Or if you're using 'js-mode' (a.k.a 'javascript-mode')
(eval-after-load 'js
'(define-key js-mode-map (kbd "C-c b") 'web-beautify-js))

(eval-after-load 'json-mode
'(define-key json-mode-map (kbd "C-c b") 'web-beautify-js))

(eval-after-load 'sgml-mode
'(define-key html-mode-map (kbd "C-c b") 'web-beautify-html))

(eval-after-load 'css-mode
'(define-key css-mode-map (kbd "C-c b") 'web-beautify-css))

Expand All @@ -52,6 +58,12 @@ add the following hook to your emacs configuration:
(lambda ()
(add-hook 'before-save-hook 'web-beautify-js-buffer t t))))

;; Or if you're using 'js-mode' (a.k.a 'javascript-mode')
(eval-after-load 'js
'(add-hook 'js-mode-hook
(lambda ()
(add-hook 'before-save-hook 'web-beautify-js-buffer t t))))

(eval-after-load 'json-mode
'(add-hook 'json-mode-hook
(lambda ()
Expand Down

0 comments on commit f9c887a

Please sign in to comment.