---
title: update()
framework: appkit
role: symbol
role_heading: Instance Method
path: appkit/nsmenu/update()
---

# update()

Enables or disables the menu items of the menu based on the NSMenuValidation informal protocol and sizes the menu to fit its current menu items if necessary.

## Declaration

```swift
func update()
```

## Discussion

Discussion For more information, see NSMenuValidation.

## See Also

### Enabling and Disabling Menu Items

- [autoenablesItems](appkit/nsmenu/autoenablesitems.md)
