Hello Parsoid developers,
I was looking at the Wikitech-l email regarding Parsoid, so I would like to mention my use case. I have an extension I maintain called StructuredNavigation. Here is it how it works:
- It implements a custom content handler that extends the default JSON content handler, in the Navigation namespace. This is where data for "navigations" go, which is intended as another way of writing navboxes with JSON instead.
- The user writes JSON in the Navigation namespace.
- The user uses the MW extension-registered parser tag, which requires one attribute, which must be a valid title name in the Navigation namespace.
- The JSON is retrieved from that page in the Navigation namespace, which is then transformed to HTML with CSS loaded with ResourceLoader.
So for example:
- A page is created at
Navigation:Dontnod Entertainment
. - A wiki page is created, with the content:
<mw-navigation title="Dontnod Entertainment" />
. - They press submit.
- The JSON is retrieved, processed, and then transformed to an HTML navigation box on final output.
I'm aware that this use case of how this parser tag is being used is probably unique among many extensions. From what I could tell, this use case didn't follow under any of the ones already listed. If the team can confirm that it does not follow under any of the 4 listed, is this something that could also be planned to add support for?
To note, this parser tag doesn't accept any text inside; it is a self-closing parser tag. If the title that the user passes doesn't exist, there is simply no HTML rendered instead.