showIf="script"
Optional. This attribute specifies that the item appears on the toolbar only if the script returns a true value. For example, you can use the showIf attribute to show certain buttons only when a page is written in a certain server-side language such as ColdFusion, ASP, or JSP. If you do not specify showIf, the item always appears.
The showIf attribute is checked whenever the item's enabler runs; that is, according to the value of the update attribute. You should use the showIf attribute sparingly.
You can specify the showIf attribute in the item definition and in a reference to the item on an itemref tag. If the definition and the reference specify the showIf attribute, the item shows only if both conditions are true. The showIf attribute is the same as the showIf() function in a toolbar command file. If you specify both the showIf attribute and the showif() function, the function overrides the attribute.
Example
showIf="dw.canLiveDebug()"