# SoundSlotElement

Class · extends [`AsyncElement`](https://api.playcanvas.com/web-components/classes/AsyncElement.md) · category: Components

Source: https://github.com/playcanvas/web-components/blob/252f001881302c266c8d727044408c32be2bb5e7/src/components/sound-slot.ts#L19

The SoundSlotElement interface provides properties and methods for manipulating
`<pc-sound-slot>` elements. The SoundSlotElement interface also inherits the properties and
methods of the [AsyncElement](https://api.playcanvas.com/web-components/classes/AsyncElement.md) interface.

**elementSummary** The `<pc-sound-slot>` element declares one named sound on its parent `<pc-sound>`
— its asset, volume, pitch, looping and autoplay. Must be a direct child of `<pc-sound>`.

## Properties

### soundSlot

```ts
soundSlot: SoundSlot | null = null
```

The sound slot.

## Accessors

### asset

```ts
get asset(): string
set asset(value: string)
```

Gets the id of the `pc-asset` to use for the sound slot.

### autoPlay

```ts
get autoPlay(): boolean
set autoPlay(value: boolean)
```

Gets the auto play flag of the sound slot.

### duration

```ts
get duration(): number | null
set duration(value: number | null)
```

Gets the duration of the sound slot.

### loop

```ts
get loop(): boolean
set loop(value: boolean)
```

Gets the loop flag of the sound slot.

### name

```ts
get name(): string
set name(value: string)
```

Gets the name of the sound slot.

### overlap

```ts
get overlap(): boolean
set overlap(value: boolean)
```

Gets the overlap flag of the sound slot.

### pitch

```ts
get pitch(): number
set pitch(value: number)
```

Gets the pitch of the sound slot.

### startTime

```ts
get startTime(): number
set startTime(value: number)
```

Gets the start time of the sound slot.

### volume

```ts
get volume(): number
set volume(value: number)
```

Gets the volume of the sound slot.

## Inherited from [AsyncElement](https://api.playcanvas.com/web-components/classes/AsyncElement.md)

- `get closestApp(): AppElement | null`
- `get closestEntity(): EntityBaseElement | null`
- `protected _onReady(): void`
- `protected _resetReady(): void`
- `ready(): Promise<SoundSlotElement>`
