# ConditionalRule Interface

> ConditionalRule interface in the TX Sheet Control TypeScript API for the browser, with 4 properties and a TypeScript example.

- **Product:** TX Sheet Control
- **Section:** Documentation
- **Kind:** Interface
- **Path:** TX Sheet Control > API Reference > TypeScript API > Browser Editor > ConditionalRule Interface
- **400 words**
- **Web URL:** https://docs.textcontrol.com/tx-sheet-control/reference/typescript-api/browser/conditionalrule/
- **LLMs URL:** https://docs.textcontrol.com/tx-sheet-control/reference/typescript-api/browser/conditionalrule/llms.txt
- **LLMs-Full URL:** https://docs.textcontrol.com/tx-sheet-control/reference/typescript-api/browser/conditionalrule/llms-full.txt

---

Native conditional rule payload. Additional validated fields depend on the rule type.

Package: `@txtextcontrol/tx-sheet-control`. Version: **2.0.0**.

Type-only declaration; it is not a JavaScript runtime constructor.

### Members

#### Properties

| Property | Description |
|---|---|
| [formatting](https://docs.textcontrol.com/tx-sheet-control/reference/typescript-api/browser/conditionalrule/formatting-property/llms-full.txt) | The formatting value of ConditionalRule. |
| [id](https://docs.textcontrol.com/tx-sheet-control/reference/typescript-api/browser/conditionalrule/id-property/llms-full.txt) | The id value of ConditionalRule. |
| [ranges](https://docs.textcontrol.com/tx-sheet-control/reference/typescript-api/browser/conditionalrule/ranges-property/llms-full.txt) | The ranges value of ConditionalRule. |
| [type](https://docs.textcontrol.com/tx-sheet-control/reference/typescript-api/browser/conditionalrule/type-property/llms-full.txt) | The type value of ConditionalRule. |

### Examples

Pass the ConditionalRule value obtained from its owning control, collection, callback or operation. The function reads that value without constructing a replacement document object.

```typescript
import type { ConditionalRule } from '@txtextcontrol/tx-sheet-control';

function inspectConditionalRuleId(conditionalRule: ConditionalRule) {
    const value = conditionalRule['id'];
    console.log('ConditionalRule.id', value);
}
```

### See Also

- [TypeScript Browser Editor API](https://docs.textcontrol.com/tx-sheet-control/reference/typescript-api/browser/llms-full.txt)
- [Workbooks and Worksheets](https://docs.textcontrol.com/tx-sheet-control/spreadsheets/workbooks/llms-full.txt)

---

## In This Section

- [ConditionalRule.formatting Property](https://docs.textcontrol.com/tx-sheet-control/reference/typescript-api/browser/conditionalrule/formatting-property/llms-full.txt): ConditionalRule.formatting property in the browser TypeScript API, with its type Partial<CellStyle> | undefined and a TypeScript example.
- [ConditionalRule.id Property](https://docs.textcontrol.com/tx-sheet-control/reference/typescript-api/browser/conditionalrule/id-property/llms-full.txt): ConditionalRule.id property in the TX Sheet Control TypeScript API for the browser, with its type string | undefined and a TypeScript example.
- [ConditionalRule.ranges Property](https://docs.textcontrol.com/tx-sheet-control/reference/typescript-api/browser/conditionalrule/ranges-property/llms-full.txt): ConditionalRule.ranges property in the TX Sheet Control TypeScript API for the browser, with its type string[] and a TypeScript example.
- [ConditionalRule.type Property](https://docs.textcontrol.com/tx-sheet-control/reference/typescript-api/browser/conditionalrule/type-property/llms-full.txt): ConditionalRule.type property in the TX Sheet Control TypeScript API for the browser, with its type string and a TypeScript example.

---

## Nearby

- **Previous:** [CommentThread.isResolved Property](https://docs.textcontrol.com/tx-sheet-control/reference/typescript-api/browser/commentthread/isresolved-property/llms-full.txt)
- **Next:** [ConditionalRule.formatting Property](https://docs.textcontrol.com/tx-sheet-control/reference/typescript-api/browser/conditionalrule/formatting-property/llms-full.txt)
