marcuswestin / WebViewJavascriptBridge

An iOS/OSX bridge for sending messages between Obj-C and JavaScript in UIWebViews/WebViews
http://marcuswest.in
MIT License
14.27k stars 2.98k forks source link

按照README 第四步拷贝的js代码可能不起作用 #427

Closed LEEDuanR closed 2 years ago

LEEDuanR commented 2 years ago

WVJB Bug Report

Thanks for reporting an issue with WebViewJavascriptBridge.

Do these 4 things and I will fix your problem!

  1. Go to https://github.com/marcuswestin/WebViewJavascriptBridge and click Fork.
  2. Clone your fork, cd into it and run make test. All tests should pass!
  3. Edit Tests/WebViewJavascriptBridgeTests/BridgeTests.m and create a new, failing test which demostrates your issue.
  4. Create a pull request for https://github.com/marcuswestin/WebViewJavascriptBridge

That's it!

I will take it from there and promise that I'll fix your problem ASAP.

If you don't do this then I can't help you!

And I probably won't :)

Cheers, @marcuswestin

LEEDuanR commented 2 years ago

第四步不起作用 Copy and paste setupWebViewJavascriptBridge into your JS: 中的 WVJBIframe.src = 'https://__bridge_loaded__'; 需要替换成 WVJBIframe.src = 'wvjbscheme://__BRIDGE_LOADED__';