Skip to content

Commit 342d8e8

Browse files
author
Raymond McCrae
committed
Fix README text
1 parent c2c25e6 commit 342d8e8

File tree

1 file changed

+7
-5
lines changed

1 file changed

+7
-5
lines changed

README.md

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,19 @@
11
HTML SAX Parser for Swift 3
22
======
3-
**HTMLSAXParser** is a swift module that wraps the libxml2 HTMLParse for the purposes
4-
of providing a simple lightweight SAX parser for HTML content. SAX parsers provide
5-
an event based parsing process, where a closure you provide will be called with
6-
a series of events as the parser moves through the document.
3+
**HTMLSAXParser** is a swift module that wraps the libxml2 HTMLParser for the purposes
4+
of providing a simple lightweight SAX parser for HTML content. libxml2 is part of the
5+
Mac, iOS and Apple TV SDK, if you are developing for those platforms then you will not
6+
require any additional dependencies. SAX parsers provide an event based parsing process,
7+
where a closure you provide will be called with a series of events as the parser moves
8+
through the document.
79

810
**HTMLSAXParser** uses enums with associated types for the parsing events and a
911
simple of example of usage is: -
1012

1113
```
1214
let parser = HTMLSAXParser()
1315
do {
14-
try parser.parse(string: "<html><body>Some HTML Content</body></html>) { event in
16+
try parser.parse(string: "<html><body>Some HTML Content</body></html>") { event in
1517
switch event {
1618
case let .startElement(name, attributes, location):
1719
print("Found character : \(name)")

0 commit comments

Comments
 (0)