A javascript Inline Editor to edit "plain old ASCII" text ?
February 11, 2016 8:21 PM   Subscribe

I'm looking for an "inline editor" to be part of a web-application. Something like TinyMCE or CKeditor (both of which I've used before) but for blobs of text which are just plain old ASCII . Can you suggest one ? Details inside ...

The key thing is that I have these blobs of ASCII, they actually templates, which I need users to be able to edit.

They include line feeds and those must be represented in the edit window. They also include place markers (into which values get substituted) delineated using angle brackets and they need to represented as well.

I've found looking at "normal" inline editors that line feeds are ignored and anything in angle brackets is just not rendered.

Another thing I'd like to be able to turn off are tool bars/menus which are only relevant if the result of the editing session is HTML (eg a 'Make Bold' button).

Integration with jQuery/Bootstrap is good but not the most important thing.

Any suggestions gratefully received.
posted by southof40 to Computers & Internet (2 answers total) 1 user marked this as a favorite
 
Best answer: Ace is a JavaScript editor widget designed for editing code, so it treats things like newlines and angle brackets literally. It should work well for editing templates.

CodeMirror is a similar text editor widget designed for code.

Both of these have a bunch of extra features that you may not need, but they are customizable so you can turn off the bells and whistles if you want to.

Or you could always just use a plain HTML <textarea> element…
posted by mbrubeck at 8:55 PM on February 11, 2016 [1 favorite]


Response by poster: @mbrubeck : Thanks very much for your help. I've setted on Ace and it's working very well.
posted by southof40 at 1:58 AM on February 15, 2016


« Older Should I sell furniture to my new supervisor?   |   Does this sound like Attention Deficit Disorder? Newer »
This thread is closed to new comments.