Extension:GuidedTour/API brainstorming

Feel free to brainstorm ideas for improving the API. See 43530.

defineTour Proposal
This looks fairly different from the current version, but the internal mapping would be relatively simple. Basically, the nth step (1-indexed) becomes gt-tourName-n.

Other properties, such as, could be added to the main object passed in.

Yes, JSON object
The code in the above design is just a JSON structure, which is good as it eliminates the risk of executing arbitrary script

It can't be shoe-horned into the Schema namespace on meta-wiki, but a general JSON namespace is possible.
 * It's not currently JSON. Besides the wrapper call and no double-quoted keys, it is intended to keep allowing inline functions.  This doesn't open any new vectors, since anyone who can currently create a tour can inject arbitrary code through Common.js or an extension.  I'm not ruling out a JSON version in the future, though. Superm401 - Talk 04:01, 5 February 2013 (UTC)

Current
The current version looks like: