<template>
<div id="share">
<h1 style="text-align: center;">分享H5</h1>
<el-button round @click="open">按钮</el-button>
</div>
</template>
<script>
export default {
name: 'share',
components: {},
data() {
return {}
},
mounted: function () {
},
methods: {
open() {
tianbai.inviteShare('11', '22', '33', '44')
}
}
}
</script>
<style lang="scss">
</style>
self.context =[self.webView valueForKeyPath:@"documentView.webView.mainFrame.javaScriptContext"];
self.context.exceptionHandler = ^(JSContext *context, JSValue *exceptionValue) {
context.exception = exceptionValue;
NSLog(@"异常信息:%@", exceptionValue);
};
self.context[@"tianbai"] = self
-(void)inviteShare:(NSString *)shareInfo :(NSString *)content :(NSString *)img :(NSString *)url{
}