PREFIX st:   <http://ns.inria.fr/sparql-template/>
PREFIX fun: <http://w3id.org/sparql-generate/fn/>
PREFIX dcterms: <http://purl.org/dc/terms/>

BASE <https://saref.etsi.org/documentation/>

TEMPLATE <ontology/references.rqg>( ) {
  IF( ?references != "" , "<h2 id=\"references\">{ fun:property(<en.properties>, 'references') }</h2>\n{ ?references }" , "" )
}
SOURCE <references.html> AS ?html
SOURCE <references.md> AS ?md
WHERE {
  BIND( COALESCE( str( ?html ) , fun:markdownToHTML(?md) , "" ) AS ?references )
}

