Skip to content

Commit

Permalink
Deduplicate entries in reference index (#2302)
Browse files Browse the repository at this point in the history
  • Loading branch information
klmr authored May 9, 2023
1 parent 7b810a7 commit 44c92aa
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
1 change: 1 addition & 0 deletions NEWS.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
# pkgdown (development version)

* Remove redundant entries in the documentation index when multiple explicit `@usage` tags are provided (@klmr, #2302)
* The article index now sorts vignettes and non-vignette articles alphabetically by their filename (literally, their `basename()`), by default (@jennybc, #2253).

# pkgdown 2.0.7
Expand Down
3 changes: 2 additions & 1 deletion R/usage.R
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,8 @@ topic_funs <- function(rd) {
gens <- name[type == "fun"]
self_meth <- (name %in% gens) & (type %in% c("s3", "s4"))

purrr::map_chr(funs[!self_meth], ~ short_name(.$name, .$type, .$signature))
funs <- purrr::map_chr(funs[!self_meth], ~ short_name(.$name, .$type, .$signature))
unique(funs)
}

parse_usage <- function(x) {
Expand Down

0 comments on commit 44c92aa

Please sign in to comment.