---
title: "buildEither(second:)"
framework: charts
role: symbol
role_heading: Type Method
path: "charts/chartcontentbuilder/buildeither(second:)"
---

# buildEither(second:)

Builds a partial result from a condition that’s false.

## Declaration

```swift
static func buildEither<T1, T2>(second: T2) -> BuilderConditional<T1, T2> where T1 : ChartContent, T2 : ChartContent
```

## Parameters

- `second`: The content to use if the condition is false.

## Discussion

Discussion This method provides support for if statements with an else clause and switch statements. It produces optional chart content that is visible when the condition evaluates to false.

## See Also

### Building conditionally

- [buildIf(_:)](charts/chartcontentbuilder/buildif(_:).md)
- [buildEither(first:)](charts/chartcontentbuilder/buildeither(first:).md)
