This is how the single quotes are escaped in the js-jsx-mode documentation in emacs master: http://git.savannah.gnu.org/cgit/emacs.git/tree/lisp/progmodes/js.el?id=a7e302dc1dc18770aaf9eeedfd638f73b574bc19#n3787 (define-derived-mode js-jsx-mode js-mode "JSX" "Major mode for editing JSX. To customize the indentation for this mode, set the SGML offset variables (`sgml-basic-offset', `sgml-attribute-offset' et al.) locally, like so: (defun set-jsx-indentation () (setq-local sgml-basic-offset js-indent-level)) (add-hook \\='js-jsx-mode-hook #\\='set-jsx-indentation)" The js2-jsx-mode docstring ( https://github.com/mooz/js2-mode/blob/49f9761af75f8df2f73bef61a7742acd8c50d7fb/js2-mode.el#L11615-11623 ) is missing those escapes. You need to open an issue on that package's github/send PR to fix it. (define-derived-mode js2-jsx-mode js2-mode "JSX-IDE" "Major mode for editing JSX code. To customize the indentation for this mode, set the SGML offset variables (`sgml-basic-offset' et al) locally, like so: (defun set-jsx-indentation () (setq-local sgml-basic-offset js2-basic-offset)) (add-hook 'js2-jsx-mode-hook #'set-jsx-indentation)" ; Missing escapes for single quotes on this line PS: I was against the curly quotes too. But now I like them :) On Thu, Jul 7, 2016 at 9:46 AM Kaushal Modi wrote: > What is jsx-ide mode? Is it part of emacs? If not, the package author > needs to fix the documentation. > > The closest thing in emacs I could find was js-jsx-mode and the quotes > show up correctly for that: http://i.imgur.com/NCPpuzv.png > > On Thu, Jul 7, 2016 at 8:54 AM Marcin Borkowski wrote: > >> Hi all, >> >> Here's a snippet from a *Help* buffer for JSX-IDE mode: >> >> --8<---------------cut here---------------start------------->8--- >> JSX-IDE mode defined in ‘js2-mode.el’: >> Major mode for editing JSX code. >> >> To customize the indentation for this mode, set the SGML offset >> variables (‘sgml-basic-offset’ et al) locally, like so: >> >> (defun set-jsx-indentation () >> (setq-local sgml-basic-offset js2-basic-offset)) >> (add-hook ’js2-jsx-mode-hook #’set-jsx-indentation) >> --8<---------------cut here---------------end--------------->8--- >> >> While I do understand that I could toggle some switch to turn off these >> retarded curly quotes, but a CODE SNIPPET in a HELP BUFFER should be >> COPY-PASTEABLE BY DEFAULT. (I'm sorry for my angry tone, but this is >> yet another case of curly quotes causing problems, and giving NOTHING in >> return. And so many people warned about this - and yet this buggy >> behavior was made the default...) >> >> I'm on GNU Emacs 25.1.50.3 (commit debd49b). >> >> Best, >> >> -- >> Marcin Borkowski >> http://octd.wmi.amu.edu.pl/en/Marcin_Borkowski >> Faculty of Mathematics and Computer Science >> Adam Mickiewicz University >> >> -- > > -- > Kaushal Modi > -- -- Kaushal Modi