<!-- Do not edit this file. It is automatically generated by API Documenter. -->
[`MenuItem`](MenuItem) › [`setSection`](MenuItem/setSection)
## MenuItem.setSection() method
Sets the section this menu item should belong in. To find the section IDs of an existing menu, inspect the DOM elements to see their `data-section` attribute.
**Signature:**
```typescript
setSection(section: string): this;
```
## Parameters
| Parameter | Type | Description |
| --- | --- | --- |
| <code>section</code> | <code>string</code> | |
**Returns:**
`this`