---
title: UserTableRowCell
source: https://docs.newrelic.com/docs/new-relic-solutions/build-nr-ui/sdk-component/tables/UserTableRowCell
---

Renders a row table cell showing a particular user. This cell takes the user object as its children, which is in turn compatible with the NerdGraph user object (needing, at the very least, the `name` and `gravatar` fields).

### Usage

```jsx
import { UserTableRowCell } from 'nr1'
```

### Examples

#### Example 1

```jsx
function render() {
  const items = [
    {
      name: "John Doe",
      gravatar:
        "https://secure.gravatar.com/avatar/79988df068cb4d952284a3395412dc4f",
    },
  ];

  return (
    <Table items={items}>
      <TableHeader>
        <TableHeaderCell>User</TableHeaderCell>
      </TableHeader>

      {({ item }) => (
        <TableRow>
          <UserTableRowCell value={item} />
        </TableRow>
      )}
    </Table>
  );
}
```

### Props

| `className` string     | Appends class names to the component.Should be used only for positioning and spacing purposes.                                                                                                                                                                                                                                                                      |
| ---------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `onClick` function     | Callback fired any time the user clicks on the table cell.                                                                                                                                                                                                                                                                                                          |
| `style` object         | Inline style for custom styling.Should be used only for positioning and spacing purposes.                                                                                                                                                                                                                                                                           |
| `testId` string        | Adds a `data-test-id` attribute. Use it to target the component in unit and E2E tests.For a test id to be valid, prefix it with your nerdpack id, followed up by a dot.For example, `my-nerdpack.some-element`. **Note:** You might not see `data-test-id` attributes as they are removed from the DOM, to debug them pass a `e2e-test` query parameter to the URL. |
| `to` shape\|string     | Location object or url string to link to.Linked `TableRowCell`s are unstyled and will not show icons for external links. If the same styling as the Link component is what is desired, then use a `Link` instead as a child component within the cell.shape `pathname` REQUIREDstring `search` string `hash` string                                                 |
| `value` REQUIRED shape | User object, that requires (at least), the `name` and `gravatar` fields. This object matches with the user structure obtained from NerdGraph. shape `name` REQUIREDstring `gravatar` REQUIREDstring                                                                                                                                                                 |
