MCPcopy Create free account
hub / github.com/react-component/select / labelRender

Function labelRender

tests/Select.test.tsx:2299–2303  ·  view source on GitHub ↗
(props: LabelInValueType)

Source from the content-addressed store, hash-verified

2297 it('labelRender', () => {
2298 const onLabelRender = jest.fn();
2299 const labelRender = (props: LabelInValueType) => {
2300 const { label, value } = props;
2301 onLabelRender();
2302 return `${label}-${value}`;
2303 };
2304 const { container } = render(
2305 <Select options={[{ label: 'realLabel', value: 'a' }]} value="a" labelRender={labelRender} />,
2306 );

Callers 1

Select.tsxFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…