| badge {lifecycle} | R Documentation |
Call usethis::use_lifecycle() to import the badges in your
package. Then use the lifecycle Rd macro to insert a lifecycle
badges in your documentation, with the relevant lifecycle stage as
argument:
\lifecycle{experimental}
\lifecycle{soft-deprecated}
The badge is displayed as image in the HTML version of the documentation and as text otherwise.
If the deprecated feature is a function, a good place for this badge is at the top of the topic description (if the deprecated function is documented with other functions, it might be a good idea to extract it in its own documentation topic to prevent confusion). If it is an argument, you can put the badge in the argument description.
badge(stage)
stage |
A lifecycle stage as a string, one of:
|
The lifecycle{} macro is made available by adding this field to
DESCRIPTION (this is done automatically by
usethis::use_lifecycle()):
RdMacros: lifecycle
The macro expands to this expression:
\Sexpr[results=rd, stage=render]{lifecycle::badge("experimental")}
An Rd expression describing the lifecycle stage.
\lifecycle{soft-deprecated}:
\lifecycle{deprecated}:
\lifecycle{defunct}: