Using markdown for code

ArchivesWebsite problems & bugs → Using markdown for code

CLOSED

Pressing tab acts to change focus not indent cursor

What I expected

Indent text

What actually happened

Focus changes

Reproducing the bug

Press tab

Link

Everywhere

Additional details

To fix all that is needed is

anytextarea.onkeydown = function(event) {
    if (event.keyCode == 9 || event.which == 9) {
            e.preventDefault();
            var s = this.selectionStart;
            this.value = this.value.substring(0,this.selectionStart) + "\t" + this.value.substring(this.selectionEnd);
            this.selectionEnd = s+1;
        }
}```