René's URL Explorer Experiment


Title: GitHub - iOSCommonLibrary/KSWebView: KSWebViewDemo

Open Graph Title: GitHub - iOSCommonLibrary/KSWebView: KSWebViewDemo

X Title: GitHub - iOSCommonLibrary/KSWebView: KSWebViewDemo

Description: KSWebViewDemo. Contribute to iOSCommonLibrary/KSWebView development by creating an account on GitHub.

Open Graph Description: KSWebViewDemo. Contribute to iOSCommonLibrary/KSWebView development by creating an account on GitHub.

X Description: KSWebViewDemo. Contribute to iOSCommonLibrary/KSWebView development by creating an account on GitHub.

Opengraph URL: https://github.com/iOSCommonLibrary/KSWebView

X: @github

direct link

Domain: patch-diff.githubusercontent.com

route-pattern/:user_id/:repository
route-controllerfiles
route-actiondisambiguate
fetch-noncev2:69117482-e156-3288-3f3d-36b2d3c5d777
current-catalog-service-hashf3abb0cc802f3d7b95fc8762b94bdcb13bf39634c40c357301c4aa1d67a256fb
request-id8F5A:3E913B:3A767D2:50F19F3:6977D5D1
html-safe-nonce1cf0a7f83aaaf873e5c26b8efced9410c221ccc69dc3d6869ee191d149456ca2
visitor-payloadeyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiI4RjVBOjNFOTEzQjozQTc2N0QyOjUwRjE5RjM6Njk3N0Q1RDEiLCJ2aXNpdG9yX2lkIjoiNTQ1OTU1MDM5NDQ5OTE5MjI3NCIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9
visitor-hmaca8ac798e66375a9bd8528f65fdc5babb303bd2e1fa0b4e2b0eec972a9f8c01be
hovercard-subject-tagrepository:148104655
github-keyboard-shortcutsrepository,copilot
google-site-verificationApib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I
octolytics-urlhttps://collector.github.com/github/collect
analytics-location//
fb:app_id1401488693436528
apple-itunes-appapp-id=1477376905, app-argument=https://github.com/iOSCommonLibrary/KSWebView
twitter:imagehttps://opengraph.githubassets.com/e646f73141ba7029183c432a0457a4a870da443758fd095e13fd44fe83769699/iOSCommonLibrary/KSWebView
twitter:cardsummary_large_image
og:imagehttps://opengraph.githubassets.com/e646f73141ba7029183c432a0457a4a870da443758fd095e13fd44fe83769699/iOSCommonLibrary/KSWebView
og:image:altKSWebViewDemo. Contribute to iOSCommonLibrary/KSWebView development by creating an account on GitHub.
og:image:width1200
og:image:height600
og:site_nameGitHub
og:typeobject
hostnamegithub.com
expected-hostnamegithub.com
Noneb39e6c26c0326ac7510f4f58f7248053edc1a743c844376b8155c71ef8138521
turbo-cache-controlno-preview
go-importgithub.com/iOSCommonLibrary/KSWebView git https://github.com/iOSCommonLibrary/KSWebView.git
octolytics-dimension-user_id20927183
octolytics-dimension-user_loginiOSCommonLibrary
octolytics-dimension-repository_id148104655
octolytics-dimension-repository_nwoiOSCommonLibrary/KSWebView
octolytics-dimension-repository_publictrue
octolytics-dimension-repository_is_forktrue
octolytics-dimension-repository_parent_id118572640
octolytics-dimension-repository_parent_nwokinsunlu/KSWebView
octolytics-dimension-repository_network_root_id118572640
octolytics-dimension-repository_network_root_nwokinsunlu/KSWebView
turbo-body-classeslogged-out env-production page-responsive
disable-turbofalse
browser-stats-urlhttps://api.github.com/_private/browser/stats
browser-errors-urlhttps://api.github.com/_private/browser/errors
release9db2400e2405e5e571d97a25e1e140cfec8da1a0
ui-targetfull
theme-color#1e2327
color-schemelight dark

Links:

Skip to contenthttps://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView#start-of-content
https://patch-diff.githubusercontent.com/
Sign in https://patch-diff.githubusercontent.com/login?return_to=https%3A%2F%2Fgithub.com%2FiOSCommonLibrary%2FKSWebView
GitHub CopilotWrite better code with AIhttps://github.com/features/copilot
GitHub SparkBuild and deploy intelligent appshttps://github.com/features/spark
GitHub ModelsManage and compare promptshttps://github.com/features/models
MCP RegistryNewIntegrate external toolshttps://github.com/mcp
ActionsAutomate any workflowhttps://github.com/features/actions
CodespacesInstant dev environmentshttps://github.com/features/codespaces
IssuesPlan and track workhttps://github.com/features/issues
Code ReviewManage code changeshttps://github.com/features/code-review
GitHub Advanced SecurityFind and fix vulnerabilitieshttps://github.com/security/advanced-security
Code securitySecure your code as you buildhttps://github.com/security/advanced-security/code-security
Secret protectionStop leaks before they starthttps://github.com/security/advanced-security/secret-protection
Why GitHubhttps://github.com/why-github
Documentationhttps://docs.github.com
Bloghttps://github.blog
Changeloghttps://github.blog/changelog
Marketplacehttps://github.com/marketplace
View all featureshttps://github.com/features
Enterpriseshttps://github.com/enterprise
Small and medium teamshttps://github.com/team
Startupshttps://github.com/enterprise/startups
Nonprofitshttps://github.com/solutions/industry/nonprofits
App Modernizationhttps://github.com/solutions/use-case/app-modernization
DevSecOpshttps://github.com/solutions/use-case/devsecops
DevOpshttps://github.com/solutions/use-case/devops
CI/CDhttps://github.com/solutions/use-case/ci-cd
View all use caseshttps://github.com/solutions/use-case
Healthcarehttps://github.com/solutions/industry/healthcare
Financial serviceshttps://github.com/solutions/industry/financial-services
Manufacturinghttps://github.com/solutions/industry/manufacturing
Governmenthttps://github.com/solutions/industry/government
View all industrieshttps://github.com/solutions/industry
View all solutionshttps://github.com/solutions
AIhttps://github.com/resources/articles?topic=ai
Software Developmenthttps://github.com/resources/articles?topic=software-development
DevOpshttps://github.com/resources/articles?topic=devops
Securityhttps://github.com/resources/articles?topic=security
View all topicshttps://github.com/resources/articles
Customer storieshttps://github.com/customer-stories
Events & webinarshttps://github.com/resources/events
Ebooks & reportshttps://github.com/resources/whitepapers
Business insightshttps://github.com/solutions/executive-insights
GitHub Skillshttps://skills.github.com
Documentationhttps://docs.github.com
Customer supporthttps://support.github.com
Community forumhttps://github.com/orgs/community/discussions
Trust centerhttps://github.com/trust-center
Partnershttps://github.com/partners
GitHub SponsorsFund open source developershttps://github.com/sponsors
Security Labhttps://securitylab.github.com
Maintainer Communityhttps://maintainers.github.com
Acceleratorhttps://github.com/accelerator
Archive Programhttps://archiveprogram.github.com
Topicshttps://github.com/topics
Trendinghttps://github.com/trending
Collectionshttps://github.com/collections
Enterprise platformAI-powered developer platformhttps://github.com/enterprise
GitHub Advanced SecurityEnterprise-grade security featureshttps://github.com/security/advanced-security
Copilot for BusinessEnterprise-grade AI featureshttps://github.com/features/copilot/copilot-business
Premium SupportEnterprise-grade 24/7 supporthttps://github.com/premium-support
Pricinghttps://github.com/pricing
Search syntax tipshttps://docs.github.com/search-github/github-code-search/understanding-github-code-search-syntax
documentationhttps://docs.github.com/search-github/github-code-search/understanding-github-code-search-syntax
Sign in https://patch-diff.githubusercontent.com/login?return_to=https%3A%2F%2Fgithub.com%2FiOSCommonLibrary%2FKSWebView
Sign up https://patch-diff.githubusercontent.com/signup?ref_cta=Sign+up&ref_loc=header+logged+out&ref_page=%2F%3Cuser-name%3E%2F%3Crepo-name%3E&source=header-repo&source_repo=iOSCommonLibrary%2FKSWebView
Reloadhttps://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView
Reloadhttps://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView
Reloadhttps://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView
iOSCommonLibrary https://patch-diff.githubusercontent.com/iOSCommonLibrary
KSWebViewhttps://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView
kinsunlu/KSWebViewhttps://patch-diff.githubusercontent.com/kinsunlu/KSWebView
Notifications https://patch-diff.githubusercontent.com/login?return_to=%2FiOSCommonLibrary%2FKSWebView
Fork 0 https://patch-diff.githubusercontent.com/login?return_to=%2FiOSCommonLibrary%2FKSWebView
Star 0 https://patch-diff.githubusercontent.com/login?return_to=%2FiOSCommonLibrary%2FKSWebView
0 stars https://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView/stargazers
23 forks https://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView/forks
Branches https://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView/branches
Tags https://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView/tags
Activity https://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView/activity
Star https://patch-diff.githubusercontent.com/login?return_to=%2FiOSCommonLibrary%2FKSWebView
Notifications https://patch-diff.githubusercontent.com/login?return_to=%2FiOSCommonLibrary%2FKSWebView
Code https://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView
Pull requests 0 https://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView/pulls
Actions https://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView/actions
Projects 0 https://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView/projects
Wiki https://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView/wiki
Security 0 https://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView/security
Insights https://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView/pulse
Code https://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView
Pull requests https://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView/pulls
Actions https://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView/actions
Projects https://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView/projects
Wiki https://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView/wiki
Security https://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView/security
Insights https://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView/pulse
Brancheshttps://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView/branches
Tagshttps://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView/tags
https://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView/branches
https://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView/tags
25 Commitshttps://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView/commits/master/
https://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView/commits/master/
KSWebViewDemo.xcodeprojhttps://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView/tree/master/KSWebViewDemo.xcodeproj
KSWebViewDemo.xcodeprojhttps://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView/tree/master/KSWebViewDemo.xcodeproj
KSWebViewDemohttps://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView/tree/master/KSWebViewDemo
KSWebViewDemohttps://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView/tree/master/KSWebViewDemo
IMG_0039.pnghttps://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView/blob/master/IMG_0039.png
IMG_0039.pnghttps://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView/blob/master/IMG_0039.png
KSWebView.pnghttps://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView/blob/master/KSWebView.png
KSWebView.pnghttps://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView/blob/master/KSWebView.png
README.mdhttps://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView/blob/master/README.md
README.mdhttps://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView/blob/master/README.md
READMEhttps://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView
https://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView#欢迎使用-kswebview
https://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView#kswebview的整体结构如下图
https://raw.githubusercontent.com/kinsunlu/KSWebView/master/KSWebView.png
https://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView#用js语句的方式调用原生类对象
https://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView#例如我们想要在js中执行下列oc代码
https://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView#objective-c
https://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView#javascript
https://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView#是不是很简单只要先导入要用到的类然后就和用js写一个oc代码一样简单需要注意的是调用多个参数的方法时需要去掉所有的冒号然后将参数一次按顺序放入传参括号内就可以了例如
https://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView#objective-c-1
https://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView#javascript-1
https://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView#返回值类型
https://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView#一切js可以识别的格式都是可以被js直接使用的例如stringnumber-等等oc对象结构体等变量承接之后只可以当作方法传的值因为js无法识别这是必然js是无法使用oc对象的例如
https://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView#objective-c-2
https://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView#javascript-2
https://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView#dictionary与array
https://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView#快速的将js对象转换为nsdictionary或将js数组转换为nsarray
https://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView#dictionary
https://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView#array
https://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView#importclass--该方法在内部已经实现了不管你重复import多少次相同的class都拿到的是相同的一个所以放心大胆的用不用担心不过最好将其放在界面加载完成后importclass防止出现问题
https://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView#releaseobjects-因为内部对象都是有引用的所以只有调用了此方法才会销毁所有对象如果长期不销毁内存会越来越大严重就会导致崩溃所以请尽量在使用完oc调用后调用此方法来销毁所有oc对象
https://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView#本地数据存储模块与监听数据变化响应kvo
https://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView#有时候我们在开发过程中会遇到很多与webview交互的需求例如在html中有一个文本该文本是用来显示用户评论数的在原生有一个工具栏上面也有个显示评论数的label当用户增加一条评论的时候两个数字都要变化这时候就很麻烦了我们用cookie存储的东西客户端拿不到客户端存储的东西js又不好获得这就有了客户端与webview公用存储空间我们可以在客户端开辟一块内存专门用来存放html与原生公用的数据如果对其添加了监听kvo变化我们就可以在原生与html都收到更新会掉从而各自更新自己的界面数据
https://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView#那我们该如何使用这个存储模块呢
https://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView#向存储模块设置一个值
https://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView#objective-c-3
https://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView#javascript-3
https://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView#你还可以一次设置更新多个值
https://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView#objective-c-4
https://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView#javascript-4
https://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView#向存储模块索要一个值
https://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView#objective-c-5
https://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView#javascript-5
https://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView#对一个值添加监听者
https://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView#objective-c-6
https://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView#javascript-6
https://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView#对一个值移除监听者
https://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView#objective-c-7
https://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView#javascript-7
https://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView#移除所有值的监听者
https://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView#objective-c-8
https://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView#javascript-8
https://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView#js重置存储空间
https://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView#javascript-9
https://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView#更详细使用方法请查看demo
Readme https://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView#readme-ov-file
Please reload this pagehttps://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView
Activityhttps://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView/activity
Custom propertieshttps://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView/custom-properties
0 starshttps://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView/stargazers
2 watchinghttps://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView/watchers
0 forkshttps://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView/forks
Report repository https://patch-diff.githubusercontent.com/contact/report-content?content_url=https%3A%2F%2Fgithub.com%2FiOSCommonLibrary%2FKSWebView&report=iOSCommonLibrary+%28user%29
Releaseshttps://patch-diff.githubusercontent.com/iOSCommonLibrary/KSWebView/releases
Packages 0https://patch-diff.githubusercontent.com/orgs/iOSCommonLibrary/packages?repo_name=KSWebView
https://github.com
Termshttps://docs.github.com/site-policy/github-terms/github-terms-of-service
Privacyhttps://docs.github.com/site-policy/privacy-policies/github-privacy-statement
Securityhttps://github.com/security
Statushttps://www.githubstatus.com/
Communityhttps://github.community/
Docshttps://docs.github.com/
Contacthttps://support.github.com?tags=dotcom-footer

Viewport: width=device-width


URLs of crawlers that visited me.