Support text on URL posts

オープン
#297 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る

まだ誰も着手していません。

評価

難易度
3/5
見積もり時間
1〜2日
初心者へのやさしさ
66/100
issue の種類
機能追加
明瞭さ
おおむね明確
活発さ
活発
技術スタック
typescript
領域
api

調査の方向性

Start by reading SubmitPostOptions and the LinksAndComments.Submit SubmitRequest description in @devvit/reddit 0.15.0. Trace how reddit.submitPost builds and sends link submissions, then check the relevant type and API tests. Done when a link post accepts body text and the request carries it through, with tests covering the behavior.

索引モデルが issue の本文から書いたものです。

説明

Reddit’s public API lets a link post carry body text: POST /api/submit with kind=link, url and text. Devvit’s reddit.submitPost does not. Apps moving from PRAW or the Data API to Devvit lose this feature.

Example of a post with both: https://www.reddit.com/r/GlobalOffensive/comments/1xcxfv2/counterstrike_2_update_for_10222026/

Current behaviour (@devvit/reddit 0.15.0)

In SubmitPostOptions, the link variant is SubmitLinkOptions & { richtext?: never; text?: never; kind?: never }. TypeScript rejects any attempt to pass a body with a url.
The LinksAndComments.Submit API description (SubmitRequest) documents text and richtextJson as “Only used if kind is set to “self””. A body sent with kind: "link" therefore seems to be ignored even if the types are bypassed.

主要言語
TypeScript
スター
217
フォーク
89
PR マージ指標
30日以内にマージされた PR はありません

環境構築

このプロジェクトには開発コンテナ、Dockerfile、コントリビューションガイドがありません。まず README を読み、一般的な手順ははじめてのコントリビューションガイドを参照してください。

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

reddit/devvit のほかの issue

reddit/devvit の issue をすべて見る

似ている issue

TypeScript の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。