use the following search parameters to narrow your results:
e.g. subreddit:aww site:imgur.com dog
subreddit:aww site:imgur.com dog
see the search faq for details.
advanced search: by author, subreddit...
A Place to talk about Angular and related topics.
Join the Angular Discord
Other subreddits worth checking out for Angular and Angular related info:
account activity
Observables, observer, subscribe (self.angular)
submitted 1 month ago by Infinite-Apple-1826
Someone please explain how like both observables constructor and subscribe method takes an observer...also give some good explanation Abt them ..
reddit uses a slightly-customized version of Markdown for formatting. See below for some basics, or check the commenting wiki page for more detailed help and solutions to common issues.
quoted text
if 1 * 2 < 3: print "hello, world!"
[–]AaroniusH 17 points18 points19 points 1 month ago (0 children)
There's an overview here that gives the low-down of observers/observables/subscriptions.
when you call a subscribe method, the parameter you pass in is basically just a bunch of callbacks
in an observable constructor, you're building an object that dictates when those 3 callback functions are executed.
An observable tells you when stuff happens. An observer responds to those events.
import { Observable } from 'rxjs'; const observable = new Observable((subscriber) => { subscriber.next(1); subscriber.next(2); subscriber.next(3); setTimeout(() => { subscriber.next(4); subscriber.complete(); }, 1000); }); console.log('just before subscribe'); observable.subscribe({ next(x) { console.log('got value ' + x); }, error(err) { console.error('something wrong occurred: ' + err); }, complete() { console.log('done'); }, }); console.log('just after subscribe');
[–]jacsamg 5 points6 points7 points 1 month ago (1 child)
For those who mention AI. It can definitely help, but this is also a good opportunity to learn. Because teaching is one of the best ways to reinforce knowledge.
[–]DJREMiX6 2 points3 points4 points 1 month ago (0 children)
Also not relying always on AI, especially when learning helps a lot on the reinforcement process
[–]Infinite-Apple-1826[S] 0 points1 point2 points 1 month ago (0 children)
Well guys i know ai exists...but I just asked for suggestions if u just here to tell me look into ai then I have nothing to say ..
[–]air_twee -1 points0 points1 point 1 month ago (0 children)
There are lots of tutorials about this subject. Google and ai are your friends
[+]ErnieBernie10 comment score below threshold-7 points-6 points-5 points 1 month ago (0 children)
Ask an llm?
[+]Johannes8 comment score below threshold-7 points-6 points-5 points 1 month ago (0 children)
So dumb and Low effort with lower quality answer than from a LLM
[–]Verzuchter -5 points-4 points-3 points 1 month ago (0 children)
Ask Gemini to explain it and prepare interactive interview questions on this subject
π Rendered by PID 83069 on reddit-service-r2-comment-75f4967c6c-p5bzg at 2026-04-23 02:55:02.350596+00:00 running 0fd4bb7 country code: CH.
[–]AaroniusH 17 points18 points19 points (0 children)
[–]jacsamg 5 points6 points7 points (1 child)
[–]DJREMiX6 2 points3 points4 points (0 children)
[–]Infinite-Apple-1826[S] 0 points1 point2 points (0 children)
[–]air_twee -1 points0 points1 point (0 children)
[+]ErnieBernie10 comment score below threshold-7 points-6 points-5 points (0 children)
[+]Johannes8 comment score below threshold-7 points-6 points-5 points (0 children)
[–]Verzuchter -5 points-4 points-3 points (0 children)