Search code examples
emacsspacemacs

In Spacemacs, how do I enable web-mode .blade.php files?


What should I put in .spacemacs so that web-mode will be enabled instead of php-mode for .blade.php files in Laravel?


Solution

  • Place the following in your $HOME/.spacemacs file, in the dotspacemacs/user-config function:

    (add-to-list 'auto-mode-alist '("\\.blade.php\\'" . web-mode))