Topics with processing-role="resource-only" generate XHTML
See original GitHub issueReported to me by a user (not sure which OT version), but I replicated with 2.1.1. If a map has nothing but key definitions (that is, nothing but references with processing-role="resource-only"
), XHTML output still generates result files for each of the topics. Resource-only topics should be available to the transform for whatever reason, but should not be generating output.
To reproduce: in hierarchy.ditamap
, add processing-role="resource-only"
to every <topicref>
. Build to XHTML; all topics are still generated. PDF output fails, I assume because no real content goes in the PDF. I tested this test both with the original <topicref>
(add @processing-role
manually) and with <keydef>
(pick up default @processing-role
and add @keys
).
If I set the first topic in the map to @processing-role="normal"
, but leave the others as resource-only
, XHTML still generates all topics. PDF correctly includes only the one normal topic.
Sample set: 2077.zip
Issue Analytics
- State:
- Created 8 years ago
- Comments:20 (18 by maintainers)
Top GitHub Comments
I definitely agree with that: a resource-only topicref to a topic should never result in a resulting HTML file (or any direct reflection in any result of any type).
I sort of fear this has gotten off track because you didn’t like my use case. The original report above is pretty straightforward, and is still (I think) the most important thing we can fix.
If I have this in my map, as my only reference to
just-a-resource.dita
:<topicref href="just-a-resource.dita" processing-role="resource-only"/>
That topic reference, when built to X/HTML, results in a generated file. It should not, because the document is marked resource-only.
I don’t think that any other stipulations / caveats are necessary.