This is what javascript-mode generates with standard tabbing (I never hit the space key when making it). I'd like to have the files contain no tab characters. I can't seem to find any option in the Easy Customization mode.
Asked
Active
Viewed 761 times
5
1 Answers
7
The buffer-local indent-tabs-mode variable controls this (in general, for any mode).
Note that javascript-mode is an alias for js-mode, so there isn't a javascript-mode-hook.
(defun my-js-mode-hook ()
"Custom `js-mode' behaviours."
(setq indent-tabs-mode nil))
(add-hook 'js-mode-hook 'my-js-mode-hook)
phils
- 48,657
- 3
- 76
- 115
