# LayerMixin.align
Aligns this layer within its parent

{/* Do not edit this file. It is automatically generated by API Documenter. */}

## LayerMixin.align() method

Aligns this layer within its parent

**Signature:**

```typescript
align(type: AlignDirection): void;
```

## Parameters

<table>
  <thead>
    <tr>
      <th>
        Parameter
      </th>

      <th>
        Type
      </th>

      <th>
        Description
      </th>
    </tr>
  </thead>

  <tbody>
    <tr>
      <td>
        type
      </td>

      <td>
        [AlignDirection](../../types/align-direction)
      </td>

      <td>
        The alignment direction
      </td>
    </tr>
  </tbody>
</table>

**Returns:**

void

## Example

```ts
// Align layer to the left of its parent
layer.align("left");
```
