Skip to contents

Converts roxygen2 documentation links in pseudo-Markdown style to actual Markdown ones using downlit::autolink_url().

Usage

roxy_to_md_links(x)

Arguments

x

Markdown text with roxygen2 documentation links. A character scalar.

Value

A character scalar.

See also

Other package documentation functions: enum_fn_param_defaults(), fn_param_defaults(), roxy_blocks(), roxy_obj(), roxy_tag_value()

Examples

pal::roxy_to_md_links("[base::c()] is so short I almost forget it's there.")
#> Warning: cannot open compressed file '/home/salim/.cache/pal-roxy_tag_value-tinkr/tinkr/DESCRIPTION', probable reason 'No such file or directory'
#> [1] "[`base::c()`](https://rdrr.io/r/base/c.html) is so short I almost forget it's there."
pal::roxy_to_md_links("[`base::c()`], probably the most used base R function ever.")
#> Warning: cannot open compressed file '/home/salim/.cache/pal-roxy_tag_value-tinkr/tinkr/DESCRIPTION', probable reason 'No such file or directory'
#> [1] "[`base::c()`](https://rdrr.io/r/base/c.html), probably the most used base R function ever."
pal::roxy_to_md_links("Some functions [are magic][downlit::autolink_url]!")
#> Warning: cannot open compressed file '/home/salim/.cache/pal-roxy_tag_value-tinkr/tinkr/DESCRIPTION', probable reason 'No such file or directory'
#> [1] "Some functions [are magic](https://downlit.r-lib.org/reference/autolink.html)!"
pal::roxy_to_md_links("downlit's [`autolink_url()`][downlit::autolink_url()] seems magic!")
#> Warning: cannot open compressed file '/home/salim/.cache/pal-roxy_tag_value-tinkr/tinkr/DESCRIPTION', probable reason 'No such file or directory'
#> [1] "downlit's [`autolink_url()`](https://downlit.r-lib.org/reference/autolink.html) seems magic!"