• /
  • Log in
  • Start now


Section of <Dropdown> component.


import { DropdownSection } from 'nr1'



This component can render either declaratively, by directly passing a set of children or virtualized, by passing a render callback (function as children).

The only items allowed inside (or returned by the render callback) are of type <DropdownItem>.

The recommendation is to use the render callback when a large number of items is provided, since the item list will be virtualized by the component, thus increasing the performance.

function () => undefined

Appends class names to the component.

Should be used only for positioning and spacing purposes.


Items to render, in the shape of a list of objects. Usually, each item in the items array contains the required data to generate the corresponding <DropdownItem>.

This prop is required when rendering items with the render callback (function as children).


Callback fired when more items must be loaded. This happens when you're lazy loading the items and the items that are about to render cannot be found in the items array.

This callback should be used to fetch/load the missing items from the backend or other sources.

The returned Promise should be resolved once item data has finished loading. It will be used to determine when to refresh the list with the newly-loaded data. This callback may be called multiple times in reaction to a single scroll event.

function (
cursor: {Object //

Items to load.

) => undefined

Number of rows.

By default it's equal to length of array passed in the items prop.

You should specify the rowCount when you know the total number of items but you want to lazy load them while scrolling.


Inline style for custom styling.

Should be used only for positioning and spacing purposes.


Adds a data-test-id.

Used to target the component in unit and e2e testing.


Section title.



function () => undefined
Edit this pageCreate an issue
Copyright © 2021 New Relic Inc.

This site uses cookies 🍪

We use cookies and other similar technologies ("Cookies") on our websites and services to enhance your experience and to provide you with relevant content. By using our websites and services you are agreeing to the use of cookies. You can read more here. If you consent to our cookies, please click Yes.