---
title: "matching(_:)"
framework: charts
role: symbol
role_heading: Type Method
path: "charts/majorvaluealignment/matching(_:)"
---

# matching(_:)

Align to calendar components.

## Declaration

```swift
static func matching(_ components: DateComponents) -> MajorValueAlignment<Value> where Value == Date
```

## Parameters

- `components`: The alignment components.
