{"id":351,"date":"2023-01-20T05:00:00","date_gmt":"2023-01-20T13:00:00","guid":{"rendered":"https:\/\/www.angulartraining.com\/daily-newsletter\/?p=351"},"modified":"2023-02-03T14:44:11","modified_gmt":"2023-02-03T22:44:11","slug":"how-to-learn-more-about-rxjs-operators","status":"publish","type":"post","link":"https:\/\/www.angulartraining.com\/daily-newsletter\/how-to-learn-more-about-rxjs-operators\/","title":{"rendered":"How to learn more about RxJs operators?"},"content":{"rendered":"\n<p>In the past weeks, we covered a few different <a href=\"https:\/\/www.angulartraining.com\/daily-newsletter\/category\/rxjs\/operators\/\" target=\"_blank\" rel=\"noopener\" title=\"\">RxJs operators<\/a> in this newsletter. RxJs is the most difficult thing to learn about Angular, and that&#8217;s because the technology is a mix of concepts that are not always obvious on their own: asynchronous data and callbacks, functional programming, streams, etc.<\/p>\n\n\n\n<p>My favorite resource to learn more about RxJs is to use a website called <a href=\"https:\/\/rxmarbles.com\/\" target=\"_blank\" rel=\"noopener\" title=\"\">rxmarbles.com<\/a>. Why? Because that website features <strong>interactive diagrams<\/strong> of RxJs operators.<\/p>\n\n\n\n<p>Let&#8217;s take an example with <code>mergeMap<\/code>. Here&#8217;s the official definition of <code>mergeMap<\/code>: <\/p>\n\n\n\n<blockquote class=\"wp-block-quote is-layout-flow wp-block-quote-is-layout-flow\">\n<p>Projects each source value to an Observable which is merged in the output Observable.<\/p>\n<cite><a href=\"https:\/\/rxjs.dev\/api\/index\/function\/mergeMap\" target=\"_blank\" rel=\"noopener\" title=\"\">Rxjs.dev<\/a> documentation<\/cite><\/blockquote>\n\n\n\n<p>And here&#8217;s an <a href=\"https:\/\/rxmarbles.com\/#mergeMap\" target=\"_blank\" rel=\"noopener\" title=\"\">interactive diagram<\/a> from RxJs marbles for <code>mergeMap<\/code> &#8211; I just recorded my screen while interacting with the diagram by dragging data around:<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"992\" height=\"400\" src=\"https:\/\/www.angulartraining.com\/daily-newsletter\/wp-content\/uploads\/2023\/01\/rxmarbles-1.gif\" alt=\"\" class=\"wp-image-354\"\/><\/figure>\n\n\n\n<p>They say a picture is worth a thousand words. An interactive picture is even better, and that&#8217;s exactly what <a href=\"https:\/\/rxmarbles.com\/\" target=\"_blank\" rel=\"noopener\" title=\"\">rxmarbles.com<\/a> is. No text, just interactive diagrams.<\/p>\n\n\n\n<p><strong>Note:<\/strong> Not all operators are documented on that website, just some of the most useful ones. At times, the operator&#8217;s signature or name is slightly different depending on the version of RxJs you&#8217;re using. Still, overall, RxJS Marbles remains one of the very best tools for understanding operators.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>In the past weeks, we covered a few different RxJs operators in this newsletter. RxJs is the most difficult thing to learn about Angular, and that&#8217;s because the technology is a mix of concepts that are not always obvious on their own: asynchronous data and callbacks, functional programming, streams, etc. My favorite resource to learn [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[12,10],"tags":[],"class_list":["post-351","post","type-post","status-publish","format-standard","hentry","category-operators","category-rxjs"],"aioseo_notices":[],"_links":{"self":[{"href":"https:\/\/www.angulartraining.com\/daily-newsletter\/wp-json\/wp\/v2\/posts\/351","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.angulartraining.com\/daily-newsletter\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.angulartraining.com\/daily-newsletter\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.angulartraining.com\/daily-newsletter\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.angulartraining.com\/daily-newsletter\/wp-json\/wp\/v2\/comments?post=351"}],"version-history":[{"count":3,"href":"https:\/\/www.angulartraining.com\/daily-newsletter\/wp-json\/wp\/v2\/posts\/351\/revisions"}],"predecessor-version":[{"id":356,"href":"https:\/\/www.angulartraining.com\/daily-newsletter\/wp-json\/wp\/v2\/posts\/351\/revisions\/356"}],"wp:attachment":[{"href":"https:\/\/www.angulartraining.com\/daily-newsletter\/wp-json\/wp\/v2\/media?parent=351"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.angulartraining.com\/daily-newsletter\/wp-json\/wp\/v2\/categories?post=351"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.angulartraining.com\/daily-newsletter\/wp-json\/wp\/v2\/tags?post=351"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}