uniapp - 右上角分享

onLoad同级,有图片就用图片,没图片就直接用屏幕截图

    onShareAppMessage() {
        let that = this;
        let pages = getCurrentPages();
        let route = pages[pages.length - 1].$page.fullPath;
        let imageUrl = that.shareUrl || ‘‘;
        if (imageUrl != ‘‘) {
            return {
                title: ‘XXX‘,
                path: route,
                imageUrl: imageUrl,
            };
        } else {
            return {
                title: ‘XXX‘,
                path: route,
            };
        }
    },

uniapp - 右上角分享

上一篇:.net core项目设置启动地址


下一篇:NET::ERR_CERT_COMMON_NAME_INVALID