Skip to content

Commit

Permalink
Improvements on parseType=Literal, but control of whitespace remains …
Browse files Browse the repository at this point in the history
…an issue.
  • Loading branch information
gkellogg committed Jun 19, 2023
1 parent ccfaab7 commit 8f56b7f
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion lib/rdf/rdfxml/writer.rb
Expand Up @@ -344,7 +344,9 @@ def render_property(property, objects, builder, **options)
render_subject(object, b, **options)
end
elsif object.literal? && object.datatype == RDF.XMLLiteral
builder.tag!(property, object.value, "rdf:parseType": "Literal")
builder.tag!(property, "rdf:parseType": "Literal") do |b|
b << object.value
end
elsif object.literal?
attrs = {}
attrs[:"xml:lang"] = object.language if object.language?
Expand Down

0 comments on commit 8f56b7f

Please sign in to comment.