README.md in sax-machine-1.1.1 vs README.md in sax-machine-1.2.0
- old
+ new
@@ -78,10 +78,13 @@
ancestor :ancestor
end
class Atom
include SAXMachine
- element :title
+ # Use block to modify the returned value
+ element :title do |title|
+ title.strip
+ end
# The :with argument means that you only match a link tag
# that has an attribute of type: "text/html"
element :link, value: :href, as: :url, with: {
type: "text/html"
}