-
Notifications
You must be signed in to change notification settings - Fork 2
Open
Description
Problem
The current RNC schema of Schematron does not contain any documentation related strings. It is not clear from looking at the schema what these elements and attributes really mean. You have to read the specification.
Suggested solution
It is quite easy to document elements and attribute. For example, this is an original snippet:
attribute id { xsd:ID }?,
to add documentation, use this:
## Identifies the unique ID value of the element
attribute id { xsd:ID }?,
To make this fly, I'd recommend:
- Make the documentation string short and sweet. There is no need to add lengthy paragraphs.
- Provide links to the Schematron specification for further details.
- Create patterns when attributes are needed for more elements. That simplifies and improves reuse. There is no need to repeat yourself.
Benefits
IMHO, adding documentation inside the Schematron schema has these benefits:
- Gives guiding aids. Some XML editors can show this as a popup when trying to add a new element or attribute.
- Help beginners to get accustomed to Schematron schema. This works quite good in combination with the first item.
- Reduces time spent to find out about the meaning of an element/attribute. Sometimes it's enough to let your XML editor show the help without looking for the specification.
- Allows to link it to the Schematron specification, if wanted.
Metadata
Metadata
Assignees
Labels
No labels