6

I'm searching for a script to (vertically) expand the text field in questions and answers as I type.
I personally prefer seeing all content at once (while the area can be extended by manually dragging, this process gets weary and impairs my workflow). The default length in desktop view is only 9-10 lines, far too narrow especially for code.

Note that "Click to expand code regions" script doesn't achieve what I'm asking, only code regions are affected and the script doesn't work automatically.

0

2 Answers 2

4

Yeah, that's annoying and a problem with text areas throughout the interwebz.

So, I went ahead and banged out a script for this; Merry Christmas!

To install, click here (SE WMD scrollbar killer, install at GitHub).

To preview the source, click here (SE WMD scrollbar killer, preview at GitHub).

This script expands away the vertical scrollbar for all open post inputs. It re-expands, as necessary, when new inputs are opened, or text is typed or pasted.

Go from this:

          default size

To this:

          decent size

Automatically.



Notes:

  • There is no shrink. Inputs are expanded only.
  • Note that "WMD" is Stack Exchange's name, not mine.
  • Tested on Chrome(like) browsers using Tampermonkey.
2
  • Is it possible to update the script to dynamically shrink the field as well? That would be very useful when removing long code snippets.
    – user598527
    Commented Oct 31, 2018 at 20:06
  • @user598527, possibly. Bit of a low priority for me. Make a feature request at GitHub (source link in the answer) and include pictures of "before" and desired "after". Commented Oct 31, 2018 at 20:10
1

and this too: StackOverflow CodeBox Options

options-menu

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .