https://github.com/afeiship/webview-bridge
Webview bridge.
https://github.com/afeiship/webview-bridge
android bridge h5 ios webview
Last synced: 28 days ago
JSON representation
Webview bridge.
- Host: GitHub
- URL: https://github.com/afeiship/webview-bridge
- Owner: afeiship
- License: mit
- Created: 2016-10-21T05:01:05.000Z (over 8 years ago)
- Default Branch: main
- Last Pushed: 2025-02-25T04:57:59.000Z (2 months ago)
- Last Synced: 2025-03-16T08:17:35.996Z (about 1 month ago)
- Topics: android, bridge, h5, ios, webview
- Language: TypeScript
- Homepage:
- Size: 11.7 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE.txt
Awesome Lists containing this project
README
# webview-bridge
> Webview bridge.[![version][version-image]][version-url]
[![license][license-image]][license-url]
[![size][size-image]][size-url]
[![download][download-image]][download-url]## installation
```shell
npm install @jswork/webview-bridge
```## usage
```js
import {callHandler, registerHandler} from '@jswork/webview-bridge'// callHandler
callHandler('closeWindow', {name: 'test'})// registerHandler
registerHandler('closeWindow', (data) => {
console.log(data)
})
```## license
Code released under [the MIT license](https://github.com/afeiship/webview-bridge/blob/master/LICENSE.txt).[version-image]: https://img.shields.io/npm/v/@jswork/webview-bridge
[version-url]: https://npmjs.org/package/@jswork/webview-bridge[license-image]: https://img.shields.io/npm/l/@jswork/webview-bridge
[license-url]: https://github.com/afeiship/webview-bridge/blob/master/LICENSE.txt[size-image]: https://img.shields.io/bundlephobia/minzip/@jswork/webview-bridge
[size-url]: https://github.com/afeiship/webview-bridge/blob/master/dist/webview-bridge.min.js[download-image]: https://img.shields.io/npm/dm/@jswork/webview-bridge
[download-url]: https://www.npmjs.com/package/@jswork/webview-bridge