The method of the iOS weex custom component cannot be executed

customizes a component in iOS and provides a method, but prompts funcation undefined .

when vue is called.
// iOS
[WXSDKEngine registerComponent:@"rich-image" withClass:[KSWXImgComponent class]];

// KSWXImgComponent.m
WX_EXPORT_METHOD(@selector(save:))
- (void)save:(WXKeepAliveCallback)resultCallback {
}
// vue
<rich-image ref="test"></rich-image>
this.$refs["test"].save()
Aug.29,2021
After the

problem is solved, please adopt the answer to end it; if you find your own solution, you can answer it yourself and adopt it. Have you solved the problem of


weex undefine

Menu