Use trailing commas in the editor inits

Discussions and requests related to new CMSimple features, plugins, templates etc. and how to develop.
Please don't ask for support at this forums!
Post Reply
cmb
Posts: 12719
Joined: Tue Jun 21, 2011 11:04 am
Location: Mü-Sa, RLP, DE
Contact:

Use trailing commas in the editor inits

Post by cmb » Wed Jan 03, 2018 11:40 am

Hi everybody!

Unless we're changing the editor inits to JSON, I suggest that we use trailing commas to ease customization. Trailing commas in object literals are allowed by the ES 5.1 specification, and are supported by all contemporary browsers (that excludes IE ≤ 9, what shouldn't be an issue). See https://developer.mozilla.org/en-US/doc ... ing_commas for details.

My main motivation for suggesting this is to simplify documentation on adding additional configuration options to the inits. It would be much simpler to tell user to insert a new line, instead of also telling where to add and remove a comma, respectively – and a missing comma would break TinyMCE.
Christoph M. Becker –Plugins for CMSimple_XH, but not for CMSimple 4+

Post Reply