更新记录

0.1.1(2026-03-27)

  • chore: 优化文档

0.1.0(2026-03-18)

  • feat: 优化一下安卓分享到朋友圈

0.0.9(2026-03-15)

  • feat: 安卓分享图文到微信朋友圈
查看更多

平台兼容性

uni-app(4.85)

Vue2 Vue3 Chrome Safari app-vue app-nvue Android iOS 鸿蒙
- - 4.4 -
微信小程序 支付宝小程序 抖音小程序 百度小程序 快手小程序 京东小程序 鸿蒙元服务 QQ小程序 飞书小程序 小红书小程序 快应用-华为 快应用-联盟
- - - - - - - - - - - -

uni-app x(4.83)

Chrome Safari Android iOS 鸿蒙 微信小程序
- - - -

lime-share

  • lime-share 调用系统分享组件发送分享消息,可分享文本、图片、视频、文件,兼容uniappX(安卓,ios)

文档

🚀 share【站点1】 🌍 share【站点2】 🔥 share【站点3】

安装

插件市场导入即可

使用

import {shareWithSystem, type ShareOption} from '@/uni_modules/lime-share'

// 分享文本
shareWithSystem({
    type: 'text',
    title: '分享到',
    summary: '这是一条重要又很不一般的文本'
} as ShareOption)

// 分享图片
uni.chooseImage({
    count: 1,
    success(res) {
        shareWithSystem({
            type: 'image',
            title: '分享到',
            path: res.tempFilePaths[0]
        } as ShareOption)
    }
})

// 分享图文(仅 Android 支持直接分享到微信朋友圈)
// 注意:图文分享在 Android 平台只在分享到微信朋友圈时有效
uni.chooseImage({
    count: 1,
    success(res) {
        shareWithSystem({
            type: 'image-text',
            title: '分享到',
            summary: '这是一条重要又很不一般的文本,配合图片一起分享',
            path: res.tempFilePaths[0]
        } as ShareOption)
    }
})

// 分享视频
uni.chooseVideo({
    success(res) {
        shareWithSystem({
            type: 'video',
            title: '分享到',
            path: res.tempFilePath
        } as ShareOption)
    }
})

// 分享文件 用到了 lime-choose-file 文件选择 https://ext.dcloud.net.cn/plugin?id=17636
chooseFile({
    success(res){
        shareWithSystem({
            type: 'file',
            title: '分享到',
            path: res.tempFiles[0].path
        } as ShareOption)
    }
} as ChooseFileOption)

注意事项

图文分享(image-text)

  • Android:直接跳转到微信朋友圈分享页面,支持同时分享文字和图片
  • iOS:使用系统分享面板,用户需要手动选择分享目标应用
  • 使用图文分享前会自动检查微信是否安装,未安装时会返回错误

打赏

如果你觉得本插件,解决了你的问题,赠人玫瑰,手留余香。

隐私、权限声明

1. 本插件需要申请的系统权限列表:

2. 本插件采集的数据、发送的服务器地址、以及数据用途说明:

3. 本插件是否包含广告,如包含需详细说明广告表达方式、展示频率: