Item
The Item component takes a data object and renders it using a render prop or wraps it in an HTML element.
This component is used as a direct child of the Items fragment.
Props
Name
Required
Default
Description
classesNo
{}A classname hash
hasFocusNo
falseSet to
true if the browser is currently focused on the itemisSelectedNo
falseSet to
true if the item is currently selecteditemYes
A data object. If this is a string, it is rendered as a child
renderYes
'div'A render prop or HTML tagname string, such as
"div".Example
import Item from "@magento/peregrine";
<Item
classes={{ root: "foo" }}
item={{ id: "s", value: "Small" }}
render="span"
/>;