nav_prepend: Append or prepend nav item to a dropdown menu

View source: R/nav-update.R

nav_prependR Documentation

Description

Exported for use by shiny::prependTab()/shiny::appendTab(). These functions have been superseded by nav_insert() (i.e., shiny::insertTab()), since it can do everything these functions do (i.e., add a nav_panel() to the start or end of a nav_menu()) and more (i.e., insert a nav_panel() anywhere inside a nav container).

Usage

nav_prepend(
  id,
  nav,
  menu_title,
  select = FALSE,
  session = get_current_session()
)

nav_append(
  id,
  nav,
  menu_title,
  select = FALSE,
  session = get_current_session()
)

Arguments

id

a character string used to identify the nav container.

nav

a nav_panel() item.

menu_title

The title of a nav_menu().

select

Should nav be selected upon being inserted?

session

a shiny session object (the default should almost always be used).


bslib documentation built on Sept. 11, 2024, 7:49 p.m.