{"id":13602192,"url":"https://github.com/Naituw/WBWebViewConsole","last_synced_at":"2025-04-11T08:31:46.527Z","repository":{"id":41322435,"uuid":"30746599","full_name":"Naituw/WBWebViewConsole","owner":"Naituw","description":"In-App debug console for your UIWebView \u0026 WKWebView","archived":false,"fork":false,"pushed_at":"2017-08-08T12:20:38.000Z","size":880,"stargazers_count":1334,"open_issues_count":7,"forks_count":124,"subscribers_count":43,"default_branch":"master","last_synced_at":"2025-04-02T05:27:48.682Z","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":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Naituw.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":"2015-02-13T08:05:55.000Z","updated_at":"2025-02-21T21:15:29.000Z","dependencies_parsed_at":"2022-08-26T08:40:59.170Z","dependency_job_id":null,"html_url":"https://github.com/Naituw/WBWebViewConsole","commit_stats":null,"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Naituw%2FWBWebViewConsole","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Naituw%2FWBWebViewConsole/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Naituw%2FWBWebViewConsole/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Naituw%2FWBWebViewConsole/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Naituw","download_url":"https://codeload.github.com/Naituw/WBWebViewConsole/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247994120,"owners_count":21030050,"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":[],"created_at":"2024-08-01T18:01:16.038Z","updated_at":"2025-04-11T08:31:46.506Z","avatar_url":"https://github.com/Naituw.png","language":"Objective-C","readme":"# WBWebViewConsole [![Build Status](https://travis-ci.org/Naituw/WBWebViewConsole.svg)](https://travis-ci.org/Naituw/WBWebViewConsole)\n\nWBWebViewConsole is an In-App debug console for your UIWebView \u0026\u0026 WKWebView\n\n\u003cimg src=\"https://github.com/Naituw/WBWebViewConsole/blob/master/Assets/hero.png\" alt=\"WBWebViewConsole\" width=\"400\"/\u003e\n\n## Installation\n\nWBWebViewConsole is available on [CocoaPods](http://cocoapods.org). Just add the following to your project Podfile:\n\n```\npod 'WBWebViewConsole', '~\u003e 1.0' \n```\n\nBugs are first fixed in master and then made available via a designated release. If you tend to live on the bleeding edge, you can use WBWebViewConsole from master with the following Podfile entry:\n\n```\npod 'WBWebViewConsole', :git =\u003e 'https://github.com/Naituw/WBWebViewConsole.git'\n```\n\n## Setup\n\n- Make your own `UIWebView` or `WKWebView` subclass, and implement all methods in `WBWebView` protocol\n- Setup `JSBridge` and `console` when WebView inits\n- If you are using `UIWebView`, inject userScript as early as possible after page loading. Otherwise, just use `WKUserScript` to implement.\n- In `UIWebView`'s `webView:shouldStartLoadWithRequest:navigationType` or `WKWebView`'s `webView:decidePolicyForNavigationAction:decisionHandler`\n  - Pass the request to `-[JSBridge handleWebViewRequest:]` and use the return value to decide whether the navigation should start\n\n## Usage\n\n- Use `WBWebViewConsole` to manage all messages\n  - `addMessage:type:level:source:`\n \t- add message for specific type, level and source\n  - `clearMessage`\n    - empty all messages\n  - `sendMessage`\n    - input (eval) script\n  - `storeCurrentSelectedElementToJavaScriptVariable:completion:`\n    - save current selected element to a js variable\n- Use `WBWebDebugConsoleViewController` to display a `WBWebViewConsole`\n  - `initWithConsole:`\n    - designated initializer for this class\n  - `setInitialCommand:`\n    - set the placeholder command\n\n## License\n\nWBWebViewConsole is BSD-licensed. see the `LICENSE` file.\n\nThe files in the `/Examples` directory are licensed under a separate license as specified in `Examples/README.md`.\n","funding_links":[],"categories":["IOS 或 OSX","Tools","Objective-C  Stars 1000以内排名整理","Objective-C"],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FNaituw%2FWBWebViewConsole","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FNaituw%2FWBWebViewConsole","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FNaituw%2FWBWebViewConsole/lists"}