Skip to content

Commit efac486

Browse files
update docs to fix disposal issue (#5851)
1 parent 3fbb37d commit efac486

1 file changed

Lines changed: 5 additions & 4 deletions

File tree

  • packages/storybook8/stories/Composites/TypeScriptLoading

packages/storybook8/stories/Composites/TypeScriptLoading/Docs.mdx

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ dependency.
7676
The following snippet is an example of how you might import the `CallComposite` in your [Angular](https://angular.dev/) application.
7777
7878
```ts
79-
import { Component } from '@angular/core';
79+
import { Component, OnDestory } from '@angular/core';
8080
import { CallCompositeOptions } from '@azure/communication-react';
8181
import { AzureCommunicationTokenCredential, CommunicationUserIdentifier } from '@azure/communication-common';
8282

@@ -86,12 +86,12 @@ import { AzureCommunicationTokenCredential, CommunicationUserIdentifier } from '
8686
templateUrl: './calling.component.html',
8787
styleUrls: ['./calling.component.css']
8888
})
89-
export class CallingComponent {
89+
export class CallingComponent implements OnDestroy {
9090
userId = '<ACS User Id>';
9191
token = '<ACS Token>';
9292
displayName = 'User';
9393
groupId = '<GUID for call>';
94-
adapter: any;
94+
adapter: CallAdapter | undefined = undefined;
9595

9696
/**
9797
* This is how you would load in the CallComposite with lazy loading. This
@@ -128,7 +128,8 @@ export class CallingComponent {
128128
locator: {
129129
groupId: this.groupId
130130
},
131-
callCompositeOptions: compositeOptions
131+
callCompositeOptions: compositeOptions,
132+
formFactor: 'desktop'
132133
},
133134
compositeContainer
134135
)

0 commit comments

Comments
 (0)