Skip to content

Commit

Permalink
docs(fromEvent): update the example to match the actual API
Browse files Browse the repository at this point in the history
Resolves: ReactiveX#7245
  • Loading branch information
demensky committed Apr 9, 2023
1 parent 8e2dd88 commit 39adabb
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/internal/observable/fromEvent.ts
Original file line number Diff line number Diff line change
Expand Up @@ -204,8 +204,8 @@ export function fromEvent<T, R>(
* ```ts
* import { fromEvent } from 'rxjs';
*
* const clicksInDocument = fromEvent(document, 'click', true); // note optional configuration parameter
* // which will be passed to addEventListener
* // note optional configuration parameter which will be passed to addEventListener
* const clicksInDocument = fromEvent(document, 'click', { capture: true });
* const clicksInDiv = fromEvent(someDivInDocument, 'click');
*
* clicksInDocument.subscribe(() => console.log('document'));
Expand Down

0 comments on commit 39adabb

Please sign in to comment.