# 功能请求：在分享到discourse PWA时，显示标题而非正文的链接

**URL:** <https://meta.discourse.org/t/feature-request-link-to-title-not-body-when-sharing-to-discourse-pwa/365156>\
**Category:** Feature\
**Tags:** completed\
**Created:** [2025 年5 月 2 日 22:12 UTC](https://meta.discourse.org/t/feature-request-link-to-title-not-body-when-sharing-to-discourse-pwa/365156 "2025-05-02T22:12:00Z")\
**Posts on this page:** 1\
**Showing post:** 8

<div class="post-metadata">

作者： ![merefield](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/merefield/32/176214_2.png) [@merefield](https://meta.discourse.org/u/merefield)\
发布日期： [2025 年5 月 7 日 21:48 UTC](https://meta.discourse.org/t/feature-request-link-to-title-not-body-when-sharing-to-discourse-pwa/365156/8 "2025-05-07T21:48:19Z")

</div>

PR 在此：

> <https://github.com/discourse/discourse/pull/32631>
>
> Discourse has a fantastic feature whereby when installed as PWA (on Android or W…indows), you can share content to that Discourse from other apps and browsers.
> 
> Currently when sharing a link to a Discourse PWA, it pre-populates a draft Topic body with the link.
> 
> Whilst this is really nice already, we can improve this further. Currently, sharing a link to the body misses out on the auto-magic core feature of pasting a link in the title which simultaneously hydrates a title from the og tag and creates a one-box in the body.
> 
> This PR remedies this whilst carefully maintaining the current behaviour for text shares.
> 
> Documentation for the standard is here:
> 
> https://developer.mozilla.org/en-US/docs/Web/Progressive\_web\_apps/How\_to/Share\_data\_between\_apps
> 
> Demo of this working change is implemented in this plugin:
> 
> https://github.com/merefield/discourse-share-to-link-oneboxer
> 
> I added a test to check presence of share target in manifest endpoint.

---

_[View the full topic](https://meta.discourse.org/t/feature-request-link-to-title-not-body-when-sharing-to-discourse-pwa/365156)._
