emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] master c0b09f4 2/2: * etc/NEWS: Document way to revert to


From: Jackson Ray Hamilton
Subject: [Emacs-diffs] master c0b09f4 2/2: * etc/NEWS: Document way to revert to old JSX indentation behavior
Date: Tue, 9 Apr 2019 21:52:44 -0400 (EDT)

branch: master
commit c0b09f42f5107dc009629ee73a790ca1d62d290a
Author: Jackson Ray Hamilton <address@hidden>
Commit: Jackson Ray Hamilton <address@hidden>

    * etc/NEWS: Document way to revert to old JSX indentation behavior
---
 etc/NEWS | 19 +++++++++++++------
 1 file changed, 13 insertions(+), 6 deletions(-)

diff --git a/etc/NEWS b/etc/NEWS
index 620d88c..81b7d26 100644
--- a/etc/NEWS
+++ b/etc/NEWS
@@ -1294,12 +1294,19 @@ conventions.
 
 ---
 *** Indentation uses 'js-indent-level' instead of 'sgml-basic-offset'.
-It was never really intuitive that JSX indentation would be controlled
-by an SGML variable.  JSX is a syntax extension of JavaScript, so it
-should be indented just like any other expression in JavaScript.  This
-is technically a breaking change, but it will probably align with how
-you would normally expect for this indentation to be controlled, and
-you probably won't need to change your config.
+Since JSX is a syntax extension of JavaScript, it makes the most sense
+for JSX expressions to be indented the same number of spaces as other
+JS expressions.  This is a breaking change, but it probably aligns
+with how you'd expect this indentation to behave.  If you want JSX to
+be indented like JS, you won't need to change your config.
+
+The old behavior can be emulated by controlling JSX indentation
+independently of JS, by setting 'js-jsx-indent-level'.
+
+---
+*** New defcustom 'js-jsx-indent-level' for different JSX indentation.
+If you wish to indent JSX by a different number of spaces than JS, set
+this variable to the desired number.
 
 ---
 *** New defcustom 'js-jsx-attribute-offset' for JSX attribute indents.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]