就一个空白测试页面,只引用了tensorflow,在微信小程序中一切正常,但是在企业微信中会直接闪退
import { View } from '@tarojs/components';
import Taro, { requirePlugin } from '@tarojs/taro';
import * as webgl from '@tensorflow/tfjs-backend-webgl';
import * as tf from '@tensorflow/tfjs-core';
import React from 'react';
import { fetchFunc, setWechatFetch } from 'fetch-wechat';
setWechatFetch(false);
export default class Test extends React.Component {
componentDidMount(): void {
const tfjsPlugin = requirePlugin('tfjsPlugin');
Taro.setInnerAudioOption({
obeyMuteSwitch: false,
});
tfjsPlugin.configPlugin({
fetchFunc: fetchFunc(),
tf,
webgl,
canvas: Taro.createOffscreenCanvas(),
});
}
render() {
return <View></View>;
}
}
企业微信相关问题请到企业微信社区咨询 https://developer.work.weixin.qq.com/community/question