/ta

TA.js A super tiny textarea code editor.

Primary LanguageJavaScriptMIT LicenseMIT

TA.js

A super tiny textarea code editor
icon

features

  • Auto height
  • Tab insert
  • Auto bracket
  • Auto indent
  • range indent

usage

methods

  • TA.ah( HTMLTextAreaElement ) -> undefined
    updates textarea height according to the content.
  • TA.sizer( HTMLTextAreaElement ) -> undefined
    adds TA.ah() to input eventlistner and execute instant.
    use this if you only need auto height feature.
  • TA.editor( HTMLTextAreaElement ) -> undefined
    setup the editor. TA.sizer() also executed.

properties

  • TA.brkt=['()','{}','[]',''','"','`']
    defines bracket pairs and quotations.

LICENSE

MIT License. see LICENSE