1

textarea has an attribute dir which can accept the value auto. This makes the textarea automatically switch to RTL mode when the first letter is from an RTL language.

How can I get the current direction of the textarea in JS (that is whether it is actually RTL or LTR, not 'auto') so I can handle the text differently in my code?

IttayD
  • 28,271
  • 28
  • 124
  • 178
  • Duplicate of https://stackoverflow.com/questions/13731909/how-to-detect-that-text-typed-in-text-area-is-rtl? – Pierre Jul 12 '17 at 06:44
  • Possible duplicate of [How to detect that text typed in text-area is RTL](https://stackoverflow.com/questions/13731909/how-to-detect-that-text-typed-in-text-area-is-rtl) – Pierre Jul 12 '17 at 06:44

0 Answers0