A sensible XML and HTML parsing library for iOS and macOS, offering a modern DOM-style API with XPath and CSS query support.
Ono is an open-source library for parsing XML and HTML documents on iOS and macOS platforms. It provides a modern, DOM-style API that simplifies working with structured data, addressing the limitations of Apple's native Foundation XML parsing options. The library makes tasks like web scraping, RSS feed parsing, and XML-RPC interfacing significantly easier for Apple platform developers.
iOS and macOS developers who need to parse or manipulate XML and HTML documents in their applications, particularly those who find Foundation's NSXMLParser too cumbersome or NSXMLDocument unavailable on iOS.
Developers choose Ono because it offers a sensible, intuitive API that feels native to Apple's ecosystem while providing powerful features like XPath and CSS query support, automatic value conversion, and excellent performance through libxml2 integration.
A sensible way to deal with XML & HTML for iOS & macOS
Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.
Follows Objective-C conventions with extensive use of blocks and NSFastEnumeration, resulting in clean, readable code as shown in the Swift and Objective-C usage examples.
Powered by libxml2, providing extremely fast document parsing and traversal, which is crucial for handling large or complex documents efficiently.
Supports both XPath and CSS selectors, allowing developers to use familiar query languages for document traversal, as demonstrated in the enumerateElements methods.
Automatically converts date and number values from XML/HTML content, reducing boilerplate code for data extraction, with examples like dateValue and numberValue accessors.
Uses a DOM-style approach that loads the entire document into memory, which can be problematic for very large XML or HTML files and memory-constrained applications.
Only supports iOS and macOS, making it unsuitable for cross-platform projects or server-side applications on other operating systems, as highlighted by its focus on Apple platforms.
Requires linking the libxml2 library manually if not using CocoaPods, adding setup complexity and potential integration issues, as noted in the requirements.