remarkjs / react-markdown

Markdown component for React
https://remarkjs.github.io/react-markdown/
MIT License
12.4k stars 847 forks source link

Options linkTarget and renderers are no-longer available #789

Closed MiguelGuthridge closed 7 months ago

MiguelGuthridge commented 7 months ago

Initial checklist

Affected packages and versions

"react-markdown": "^9.0.0"

Link to runnable example

https://codesandbox.io/p/sandbox/awesome-jerry-lh8lp8?file=%2Fsrc%2Fapp.tsx%3A3%2C75

Steps to reproduce

Using Node 18, NPM 10.

I am attempting to make links open in a new tab as documented in #379 and #65, but using either the linkTarget or renderers options give a TypeScript error, and fail to render.

How can I make links open in a new tab, given that these options are no-longer available?

Expected behavior

I can make links open in a new tab easily by specifying a simple option or overriding a simple renderer.

Actual behavior

I cannot find a simple way to accomplish this common behaviour.

Runtime

Other (please specify in steps to reproduce)

Package manager

Other (please specify in steps to reproduce)

OS

Linux

Build and bundle tools

Next.js

wooorm commented 7 months ago

Hey! See the changelog: https://github.com/remarkjs/react-markdown/blob/main/changelog.md#add-urltransform, https://github.com/remarkjs/react-markdown/blob/main/changelog.md#remove-linktarget.

github-actions[bot] commented 7 months ago

Hi! This was closed. Team: If this was fixed, please add phase/solved. Otherwise, please add one of the no/* labels.