PP3 JSON output format

Please post all questions and comments regarding Help & Manual 7 here.

Moderators: Alexander Halser, Tim Green

Post Reply
Simon Dismore
Posts: 454
Joined: Thu Nov 16, 2006 1:29 pm
Location: London, UK

PP3 JSON output format

Unread post by Simon Dismore »

I'm interested in re-purposing the .js output from the new PP3 skins. So I've been importing it into various tools. Can I suggest you tweak your compilation stage so the output format is more compatible with ECMA-404 (pdf)?
  • Export as data rather than a function, i.e. rather than execute topicname.js directly have the container take a pure JSON payload file which it parses and loads via hmLoadTopic.
  • Therefore enclose key names in quotation marks, e.g. "hmKeywords": "" not hmKeywords: ""
  • Don't use two-character shortcuts other than the standard \" \\ \/ \b \c \n \r \t. Instead use either HTML entities or four-digit hex codes, e.g. IBM's cloud not IBM\'s cloud, likewise if you want to escape the dollar character use e.g. "hmPrevLink": "one-way\u0024command.html" not one-way\$command.html
  • Consider adding topic metadata to the output, e.g. the topic status, last updated date and author, possibly build tags, ID, name of the topic file. Maybe allow the author to customize the JSON output template?
  • Have the compiler add an H&M JSON schema name/number, so that future variations can be recognized and accommodated.
  • Use the same schema for popup topics, i.e. the only difference between how entire topics and popups are displayed is down to the code that loads them.
Collectively, these suggestions will allow topic json files to be stored directly as documents in NoSQL databases, opening the way to a vast range of uses ...and perhaps helping to secure H&M's central position in the documentation workflow.
User avatar
Tim Green
Site Admin
Posts: 23184
Joined: Mon Jun 24, 2002 9:11 am
Location: Bruehl, Germany
Contact:

Re: PP3 JSON output format

Unread post by Tim Green »

Hi Simon,
I'm interested in re-purposing the .js output from the new PP3 skins.
That's a little surprising, since you don't have one to test with. 8) The demo that was published in the beta forum a while ago is long out of date.
Regards,
Tim (EC Software Documentation & User Support)

Private support:
Please do not email or PM me with private support requests -- post to the forum directly.
Simon Dismore
Posts: 454
Joined: Thu Nov 16, 2006 1:29 pm
Location: London, UK

Re: PP3 JSON output format

Unread post by Simon Dismore »

Tim Green wrote:That's a little surprising, since you don't have one to test with
Err, that was me being discreet about the beta, but since you had made other references to it here I thought you were going public... I'm not surprised to hear that I'm hacking on an out-of-date version, of course. Would you prefer me to (a) discuss this elsewhere, in which case of course you can move the thread, or (b) boil my head? :!:
Post Reply