diff --git a/README.md b/README.md index 2f097cd..3c778d3 100644 --- a/README.md +++ b/README.md @@ -1,9 +1,11 @@ HTML SAX Parser for Swift 3 ====== -**HTMLSAXParser** is a swift module that wraps the libxml2 HTMLParse for the purposes -of providing a simple lightweight SAX parser for HTML content. SAX parsers provide -an event based parsing process, where a closure you provide will be called with -a series of events as the parser moves through the document. +**HTMLSAXParser** is a swift module that wraps the libxml2 HTMLParser for the purposes +of providing a simple lightweight SAX parser for HTML content. libxml2 is part of the +Mac, iOS and Apple TV SDK, if you are developing for those platforms then you will not +require any additional dependencies. SAX parsers provide an event based parsing process, +where a closure you provide will be called with a series of events as the parser moves +through the document. **HTMLSAXParser** uses enums with associated types for the parsing events and a simple of example of usage is: - @@ -11,7 +13,7 @@ simple of example of usage is: - ``` let parser = HTMLSAXParser() do { - try parser.parse(string: "Some HTML Content) { event in + try parser.parse(string: "Some HTML Content") { event in switch event { case let .startElement(name, attributes, location): print("Found character : \(name)")