---
title: "webView(_:doCommandBy:)"
framework: webkit
role: symbol
role_heading: Instance Method
path: "webkit/webeditingdelegate/webview(_:docommandby:)"
---

# webView(_:doCommandBy:)

Returns whether the receiver performs a command instead of the web view.

## Declaration

```swift
optional func webView(_ webView: WebView!, doCommandBy selector: Selector!) -> Bool
```

## Parameters

- `webView`: The web view that the user is editing.
- `selector`: The command to perform.

## Return Value

Return Value true if the receiver will perform command; otherwise, false.

## Discussion

Discussion Implement this method if you want to perform command instead of letting the web view perform command.
