{"id":13814734,"url":"https://github.com/lightory/HHRouter","last_synced_at":"2025-05-15T06:32:25.461Z","repository":{"id":14979818,"uuid":"17704954","full_name":"lightory/HHRouter","owner":"lightory","description":"Yet another URL Router for iOS.","archived":false,"fork":false,"pushed_at":"2017-12-06T09:11:29.000Z","size":65,"stargazers_count":1607,"open_issues_count":12,"forks_count":233,"subscribers_count":66,"default_branch":"master","last_synced_at":"2024-11-19T10:46:48.117Z","etag":null,"topics":["objective-c","url-router"],"latest_commit_sha":null,"homepage":"","language":"Objective-C","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/lightory.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2014-03-13T09:42:18.000Z","updated_at":"2024-10-12T12:18:51.000Z","dependencies_parsed_at":"2022-09-04T14:02:00.959Z","dependency_job_id":null,"html_url":"https://github.com/lightory/HHRouter","commit_stats":null,"previous_names":[],"tags_count":10,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lightory%2FHHRouter","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lightory%2FHHRouter/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lightory%2FHHRouter/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lightory%2FHHRouter/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/lightory","download_url":"https://codeload.github.com/lightory/HHRouter/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":254288531,"owners_count":22045913,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["objective-c","url-router"],"created_at":"2024-08-04T04:02:32.054Z","updated_at":"2025-05-15T06:32:25.153Z","avatar_url":"https://github.com/lightory.png","language":"Objective-C","funding_links":[],"categories":["Objective-C"],"sub_categories":[],"readme":"HHRouter\n=====\n[![Build Status](https://travis-ci.org/Huohua/HHRouter.png)](https://travis-ci.org/Huohua/HHRouter)\n[![CocoaPods](https://cocoapod-badges.herokuapp.com/v/HHRouter/badge.png)](http://cocoapods.org/?q=HHRouter)\n\nYet another URL Router for iOS. Clean, Fast \u0026 Flexible. Inspired by [ABRouter](https://github.com/aaronbrethorst/ABRouter) \u0026 [Routable iOS](https://github.com/usepropeller/routable-ios).\n\n## Usage\n\n### Warm Up\n\nMap URL patterns to viewController. Better in AppDelegate.\n\n```objective-c\n[[HHRouter shared] map:@\"/user/:userId/\" toControllerClass:[UserViewController class]];\n```\n\n### Exciting Time\nGet viewController instance from URL. Params will be parsed automatically.\n\n```objective-c\nUIViewController *viewController = [[HHRouter shared] matchController:@\"/user/1/\"];\n```\n\n```objective-c\nXCTAssertEqualObjects([viewController class], [UserViewController class]);\nXCTAssertEqualObjects(viewController.params[@\"route\"], @\"/user/1/\");\nXCTAssertEqualObjects(viewController.params[@\"userId\"], @\"1\");\n```\n\n### URL Query Params\n\nURL Query Params is also supported, which will make things VERY flexible.\n\n```objective-c\nUIViewController *viewController = [[HHRouter shared] matchController:@\"/user/1/?tabIndex=3\"];\n```\n\n```objective-c\nXCTAssertEqualObjects(viewController.params[@\"tabIndex\"], @\"3\");\n```\n\n### One More Thing\n\nIf your app has defined some URL schemes, HHRouter will know.\n\n```objective-c\nUIViewController *viewController = [[HHRouter shared] matchController:@\"hhrouter://user/1/\"];\n```\n\n```objective-c\nXCTAssertEqualObjects([viewController class], [UserViewController class]);\n```\n\n## Installation\n### [CocoaPods](http://cocoapods.org/)\n\n```ruby\npod 'HHRouter', '~\u003e 0.1.8'\n```\n\n```objective-c\n#import \u003cHHRouter/HHRouter.h\u003e\n```\n\nIf you're not able to use CocoaPods, please install HHRouter as a [git submodule](http://schacon.github.com/git/user-manual.html#submodules) and add the files to your Xcode project.\n\n## We're Hiring!\n[http://pudding.cc/opportunity/](http://pudding.cc/opportunity/)\n\n## Contact\n- [lightory@gmail.com](mailto:lightory@gmail.com)\n- [http://twitter.com/lightory/](http://twitter.com/lightory/)\n\n## Who use HHRouter?\nIf you're building your applications using HHRouter, please let me know! (add your application name \u0026 App Store link here and pull reuqest this README.\n\n- 布丁动画: [https://itunes.apple.com/cn/app/bu-ding-dong-hua-zui-liang/id869243194?l=zh\u0026ls=1\u0026mt=8](https://itunes.apple.com/cn/app/bu-ding-dong-hua-zui-liang/id869243194?l=zh\u0026ls=1\u0026mt=8)\n\n\n## License\nHHRouter is available under the [MIT license](https://github.com/Huohua/HHRouter/blob/master/LICENSE).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flightory%2FHHRouter","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flightory%2FHHRouter","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flightory%2FHHRouter/lists"}