From 15e710d9f209bad7d9c54aff9af713cce31a43f8 Mon Sep 17 00:00:00 2001 From: IOLOII Date: Tue, 18 Feb 2025 09:55:47 +0800 Subject: [PATCH] Update 4-async-completion.md Starting with RxJS 6.x, the Observable.of method has been removed, and it's recommended to directly import the of function from 'rxjs' instead. --- docs/getting-started/4-async-completion.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/getting-started/4-async-completion.md b/docs/getting-started/4-async-completion.md index 0fa262cd0..a3a550d03 100644 --- a/docs/getting-started/4-async-completion.md +++ b/docs/getting-started/4-async-completion.md @@ -68,10 +68,10 @@ exports.default = childProcessTask; ### Returning an observable ```js -const { Observable } = require('rxjs'); +const { of } = require('rxjs'); function observableTask() { - return Observable.of(1, 2, 3); + return of(1, 2, 3); } exports.default = observableTask;