{"id":19243580,"url":"https://github.com/devdragonli/lflrouter","last_synced_at":"2025-08-23T05:32:43.235Z","repository":{"id":127236480,"uuid":"384052304","full_name":"DevDragonLi/LFLRouter","owner":"DevDragonLi","description":"LFLRouter","archived":false,"fork":false,"pushed_at":"2021-08-09T02:47:05.000Z","size":20,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":3,"default_branch":"main","last_synced_at":"2025-02-23T14:47:15.251Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"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/DevDragonLi.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,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2021-07-08T08:18:11.000Z","updated_at":"2021-08-09T03:03:25.000Z","dependencies_parsed_at":null,"dependency_job_id":"7b9cd50a-5489-4e1a-ba7c-b3dfc8b7b1bb","html_url":"https://github.com/DevDragonLi/LFLRouter","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/DevDragonLi/LFLRouter","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DevDragonLi%2FLFLRouter","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DevDragonLi%2FLFLRouter/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DevDragonLi%2FLFLRouter/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DevDragonLi%2FLFLRouter/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/DevDragonLi","download_url":"https://codeload.github.com/DevDragonLi/LFLRouter/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DevDragonLi%2FLFLRouter/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":271745597,"owners_count":24813509,"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","status":"online","status_checked_at":"2025-08-23T02:00:09.327Z","response_time":69,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":[],"created_at":"2024-11-09T17:18:40.499Z","updated_at":"2025-08-23T05:32:43.213Z","avatar_url":"https://github.com/DevDragonLi.png","language":"Objective-C","funding_links":[],"categories":[],"sub_categories":[],"readme":"# LFLRouter\n\n### 不需要 Load 注册的`URL Router`\n\n\u003e 核心思路：load注册转化为函数映射，不需要启动便注册全部router能力，也不会影响App启动速度\n\n## Example\n\n```objc\n\n    NSString *testString = @\"LFL://usr/openuserinfo?name=lfl\u0026type=test\";\n    [[LFLRouter sharedManger] configModuleWithKey:@\"openuserinfo\" value:@\"LFLAccountTool\"]; // 此处为map映射【组件和类名不统一情况使用，一般不需要】\n\n    NSLog(@\"Router Result %@\",[[LFLRouter sharedManger] openURLString:testString]);\n\n```\n## Installation\n\nLFLRouter is available through [CocoaPods](https://cocoapods.org). To install it, simply add the following line to your Podfile:\n\n```ruby\n\n  pod 'LFLRouter', :git =\u003e 'https://github.com/DevDragonLi/LFLRouter.git'\n\n```\n\n## 核心API如下\n\n\u003e  scheme://描述/打开方式/保留字段/功能标识？参数1=值1\u0026参数2=值2\n\n```\n/** AnyClass Object Funcation\n *  Example: input a URL ,return AnyClass Object immediate\n */\n+ (nullable id)openURLString:(nullable NSString *)URLString;\n\n/** AnyClass Object Funcation\n *  Example: input a URL ,return AnyClass Object wait result in Block\n */\n+ (void)openURLString:(nullable NSString *)URLString\n           parameters:(void (^)(void))parameters;\n\n```\n\n### 端组件资源交互\n\n- Example：`Account`组件和`Setting`组件 \n\t- `Account`组件负责托管头像\n\t- `Setting`组件负责显示头像\n\n- 需要交互传递图片资源场景\n\t- `Account`需提供能力使得`Setting`组件可以通过指定 scheme  `URL`获取头像数据\n\t- `Setting `可以变更`Account `组件头像数据\n\n- 资源数据交互\n\t- 获取\n\t- 传递\n\t\t- 正常图片资源传递【本地Image资源等】\n\t\t- 其他数据类型\t\n\n### 获取头像数据：返回字典或者Image Object \n\n```\n    [LFLRouter openURLString:@\"LFL://XXX/headerImageInfo\"]\n    \n```\n\n### 组件图片资源传递【本地Image资源等】\n\n-  Account组件\n\t-  需要有本地`AccountHeaderImage`实现函数响应\n\n- Setting组件获取如下\n\n```\n  NSString *openString = [NSString stringWithFormat:@\"LFL://XXX/%@\",@{@\"AccountHeaderImage\":[UIImage new]}];\n  \n [LFLRouter openURLString:openString] ;   // 返回对应的数据给Setting组件\n    \n```\n\n### 端与H5交互\n\n\u003e 如果是远端和本地交互，则只建议基本数据类型：String，Bool，Dictionary，Array等。\n\n- 推荐用于简单界面为主。\n\t- 如果是资源类型可以传递scheme URL包装图片`URL` \n\t- 本地函数做支持即可\n\n\n## Author\n\n\u003e Dragonli_52171@163.com\n\n## License\n\nLFLRouter is available under the MIT license. See the LICENSE file for more info.","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdevdragonli%2Flflrouter","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdevdragonli%2Flflrouter","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdevdragonli%2Flflrouter/lists"}