# viewOf

function in `@dioramajs/data/map`

```ts
import { viewOf } from '@dioramajs/data/map'
```

The region's projected bounds around its middle meridian (moved by `center`), shrunk by `zoom`
and widened to the box's proportions, so the region fits and the rest of the box shows more map.

```ts
function viewOf(
  region: Region,
  center: number,
  zoom: number,
  aspect: number,
): View
```

| Parameter | Type | Description |
| --- | --- | --- |
| `region` | `Region` |  |
| `center` | `number` |  |
| `zoom` | `number` |  |
| `aspect` | `number` |  |

Defined in [packages/data/src/map.ts](https://github.com/MasterKurosava/diorama/blob/main/packages/data/src/map.ts#L206).
