<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	
	>
<channel>
	<title>
	Comments on: The Four ways to Create Loading Spinners in an Angular App	</title>
	<atom:link href="https://christianlydemann.com/four-ways-to-create-loading-spinners-in-an-angular-app/feed/" rel="self" type="application/rss+xml" />
	<link>https://christianlydemann.com/four-ways-to-create-loading-spinners-in-an-angular-app/</link>
	<description>Advanced Angular Training Made Simple</description>
	<lastBuildDate>Mon, 26 Dec 2022 11:18:31 +0000</lastBuildDate>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=6.7.4</generator>
	<item>
		<title>
		By: Angular Loading Screen? 13 Most Correct Answers - Brandiscrafts.com		</title>
		<link>https://christianlydemann.com/four-ways-to-create-loading-spinners-in-an-angular-app/#comment-172103</link>

		<dc:creator><![CDATA[Angular Loading Screen? 13 Most Correct Answers - Brandiscrafts.com]]></dc:creator>
		<pubDate>Mon, 26 Dec 2022 11:18:31 +0000</pubDate>
		<guid isPermaLink="false">https://christianlydemann.com/?p=482#comment-172103</guid>

					<description><![CDATA[[&#8230;]  + View Here [&#8230;]]]></description>
			<content:encoded><![CDATA[<p>[&#8230;]  + View Here [&#8230;]</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: elenatrudini		</title>
		<link>https://christianlydemann.com/four-ways-to-create-loading-spinners-in-an-angular-app/#comment-62623</link>

		<dc:creator><![CDATA[elenatrudini]]></dc:creator>
		<pubDate>Sun, 30 Aug 2020 13:30:00 +0000</pubDate>
		<guid isPermaLink="false">https://christianlydemann.com/?p=482#comment-62623</guid>

					<description><![CDATA[In reply to &lt;a href=&quot;https://christianlydemann.com/four-ways-to-create-loading-spinners-in-an-angular-app/#comment-62043&quot;&gt;elenatrudini&lt;/a&gt;.

Found the answer by myself: just created a property on the class called componentInstance and substituted const component with this.componentInstance, then created a function on the service updateMessage:&lt;code&gt;public updateMessage(updatedMessage) {
    (this.componentInstance.instance as any).message = updatedMessage;
  }&lt;/code&gt;]]></description>
			<content:encoded><![CDATA[<p>In reply to <a href="https://christianlydemann.com/four-ways-to-create-loading-spinners-in-an-angular-app/#comment-62043">elenatrudini</a>.</p>
<p>Found the answer by myself: just created a property on the class called componentInstance and substituted const component with this.componentInstance, then created a function on the service updateMessage:<code>public updateMessage(updatedMessage) {<br />
    (this.componentInstance.instance as any).message = updatedMessage;<br />
  }</code></p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: elenatrudini		</title>
		<link>https://christianlydemann.com/four-ways-to-create-loading-spinners-in-an-angular-app/#comment-62043</link>

		<dc:creator><![CDATA[elenatrudini]]></dc:creator>
		<pubDate>Wed, 26 Aug 2020 12:18:00 +0000</pubDate>
		<guid isPermaLink="false">https://christianlydemann.com/?p=482#comment-62043</guid>

					<description><![CDATA[In reply to &lt;a href=&quot;https://christianlydemann.com/four-ways-to-create-loading-spinners-in-an-angular-app/#comment-15329&quot;&gt;Steven Fisher&lt;/a&gt;.

Hi Steven,

I added your extra lines and passed a message as a parameter in the show() function, but I would like to update the message with a % of the tasks being completed, do you have any tips?
Here is a simplyfied version of my code:
&lt;code&gt;
ngOnInit() {
    this.spinnerOverlayService.show(&quot;0%&quot;);
    const result$ = this.contentService.getContent([&#039;articles&#039;, &#039;pages&#039;, &#039;users&#039;]);
    result$.pipe(
        mergeMap(([finalResult, progress]) =&#062; merge(
            progress.pipe(
                tap((value) =&#062; console.log(`${value}% completed`)), //here my service gives me the % of completion of my http calls, now I would like to update the spinner message with this value
            ),
            finalResult
        )),
    ).subscribe(
        (res) =&#062; {
            this.content = res;
            this.spinnerOverlayService.hide();
        },
        (err) =&#062; {
            console.log(&#039;err: &#039;, err);
            this.spinnerOverlayService.hide();
        }
    );
}
&lt;/code&gt;]]></description>
			<content:encoded><![CDATA[<p>In reply to <a href="https://christianlydemann.com/four-ways-to-create-loading-spinners-in-an-angular-app/#comment-15329">Steven Fisher</a>.</p>
<p>Hi Steven,</p>
<p>I added your extra lines and passed a message as a parameter in the show() function, but I would like to update the message with a % of the tasks being completed, do you have any tips?<br />
Here is a simplyfied version of my code:<br />
<code><br />
ngOnInit() {<br />
    this.spinnerOverlayService.show("0%");<br />
    const result$ = this.contentService.getContent(['articles', 'pages', 'users']);<br />
    result$.pipe(<br />
        mergeMap(([finalResult, progress]) =&gt; merge(<br />
            progress.pipe(<br />
                tap((value) =&gt; console.log(`${value}% completed`)), //here my service gives me the % of completion of my http calls, now I would like to update the spinner message with this value<br />
            ),<br />
            finalResult<br />
        )),<br />
    ).subscribe(<br />
        (res) =&gt; {<br />
            this.content = res;<br />
            this.spinnerOverlayService.hide();<br />
        },<br />
        (err) =&gt; {<br />
            console.log('err: ', err);<br />
            this.spinnerOverlayService.hide();<br />
        }<br />
    );<br />
}<br />
</code></p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: jay rangras		</title>
		<link>https://christianlydemann.com/four-ways-to-create-loading-spinners-in-an-angular-app/#comment-19329</link>

		<dc:creator><![CDATA[jay rangras]]></dc:creator>
		<pubDate>Fri, 01 Nov 2019 17:57:00 +0000</pubDate>
		<guid isPermaLink="false">https://christianlydemann.com/?p=482#comment-19329</guid>

					<description><![CDATA[Hello Sir, Thank you so much for this great content. I just wanted to know one thing that what to do if wanted to add a message with spinner?]]></description>
			<content:encoded><![CDATA[<p>Hello Sir, Thank you so much for this great content. I just wanted to know one thing that what to do if wanted to add a message with spinner?</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: ámbátor		</title>
		<link>https://christianlydemann.com/four-ways-to-create-loading-spinners-in-an-angular-app/#comment-16168</link>

		<dc:creator><![CDATA[ámbátor]]></dc:creator>
		<pubDate>Thu, 10 Oct 2019 16:52:00 +0000</pubDate>
		<guid isPermaLink="false">https://christianlydemann.com/?p=482#comment-16168</guid>

					<description><![CDATA[In reply to &lt;a href=&quot;https://christianlydemann.com/four-ways-to-create-loading-spinners-in-an-angular-app/#comment-365&quot;&gt;Christian Lydemann&lt;/a&gt;.

Angular beginner here.
I also struggle finding the point where the overlay is shown and hidden in your code. I tried to put overlayService.show() and hide() in the right spots in my code but all I get is either a &quot;Maximum call stack exceeded and the highlighted line is  in the SpinnerOverlayComponent.html or a &quot;Host already has a portal attached&quot; error. What did I miss in your code?]]></description>
			<content:encoded><![CDATA[<p>In reply to <a href="https://christianlydemann.com/four-ways-to-create-loading-spinners-in-an-angular-app/#comment-365">Christian Lydemann</a>.</p>
<p>Angular beginner here.<br />
I also struggle finding the point where the overlay is shown and hidden in your code. I tried to put overlayService.show() and hide() in the right spots in my code but all I get is either a &#8220;Maximum call stack exceeded and the highlighted line is  in the SpinnerOverlayComponent.html or a &#8220;Host already has a portal attached&#8221; error. What did I miss in your code?</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: Steven Fisher		</title>
		<link>https://christianlydemann.com/four-ways-to-create-loading-spinners-in-an-angular-app/#comment-15329</link>

		<dc:creator><![CDATA[Steven Fisher]]></dc:creator>
		<pubDate>Fri, 04 Oct 2019 19:02:00 +0000</pubDate>
		<guid isPermaLink="false">https://christianlydemann.com/?p=482#comment-15329</guid>

					<description><![CDATA[In reply to &lt;a href=&quot;https://christianlydemann.com/four-ways-to-create-loading-spinners-in-an-angular-app/#comment-49&quot;&gt;Mark Shaw&lt;/a&gt;.

In the SpinnerOverlayService, add an extra line:

&lt;code&gt;    const component = this.overlayRef.attach(spinnerOverlayPortal);
    (component.instance as any).message = message;
&lt;/code&gt;]]></description>
			<content:encoded><![CDATA[<p>In reply to <a href="https://christianlydemann.com/four-ways-to-create-loading-spinners-in-an-angular-app/#comment-49">Mark Shaw</a>.</p>
<p>In the SpinnerOverlayService, add an extra line:</p>
<p><code>    const component = this.overlayRef.attach(spinnerOverlayPortal);<br />
    (component.instance as any).message = message;<br />
</code></p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: Eduardo Fernández Díaz		</title>
		<link>https://christianlydemann.com/four-ways-to-create-loading-spinners-in-an-angular-app/#comment-9042</link>

		<dc:creator><![CDATA[Eduardo Fernández Díaz]]></dc:creator>
		<pubDate>Thu, 22 Aug 2019 00:33:00 +0000</pubDate>
		<guid isPermaLink="false">https://christianlydemann.com/?p=482#comment-9042</guid>

					<description><![CDATA[Nicely done!]]></description>
			<content:encoded><![CDATA[<p>Nicely done!</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: Why I Moved from Protractor to Cypress and the 7 Steps to Cypress E2E Testing Success – Christian Lüdemann		</title>
		<link>https://christianlydemann.com/four-ways-to-create-loading-spinners-in-an-angular-app/#comment-1928</link>

		<dc:creator><![CDATA[Why I Moved from Protractor to Cypress and the 7 Steps to Cypress E2E Testing Success – Christian Lüdemann]]></dc:creator>
		<pubDate>Wed, 03 Jul 2019 17:54:39 +0000</pubDate>
		<guid isPermaLink="false">https://christianlydemann.com/?p=482#comment-1928</guid>

					<description><![CDATA[[&#8230;] to appear. Here you need to explicitly tell Protractor to wait for the blocking overlay eg. the spinner overlay to disappear. Wuhu, imagine how much fun that is to [&#8230;]]]></description>
			<content:encoded><![CDATA[<p>[&#8230;] to appear. Here you need to explicitly tell Protractor to wait for the blocking overlay eg. the spinner overlay to disappear. Wuhu, imagine how much fun that is to [&#8230;]</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: Marcos Bertuol		</title>
		<link>https://christianlydemann.com/four-ways-to-create-loading-spinners-in-an-angular-app/#comment-397</link>

		<dc:creator><![CDATA[Marcos Bertuol]]></dc:creator>
		<pubDate>Thu, 02 May 2019 21:38:00 +0000</pubDate>
		<guid isPermaLink="false">https://christianlydemann.com/?p=482#comment-397</guid>

					<description><![CDATA[love you]]></description>
			<content:encoded><![CDATA[<p>love you</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: Shreekanth G		</title>
		<link>https://christianlydemann.com/four-ways-to-create-loading-spinners-in-an-angular-app/#comment-390</link>

		<dc:creator><![CDATA[Shreekanth G]]></dc:creator>
		<pubDate>Tue, 23 Apr 2019 06:07:00 +0000</pubDate>
		<guid isPermaLink="false">https://christianlydemann.com/?p=482#comment-390</guid>

					<description><![CDATA[Dear Sir,
Thank you for a wonderful article. I have gone through your git repository. There is no reference for &#039;app-spinner-overlay&#039;  and &#039;app-spinner-overlay-wrapper&#039; custom elements or  these components in your code. Could yo please explain how to use case 3 and case 4 with in example.]]></description>
			<content:encoded><![CDATA[<p>Dear Sir,<br />
Thank you for a wonderful article. I have gone through your git repository. There is no reference for &#8216;app-spinner-overlay&#8217;  and &#8216;app-spinner-overlay-wrapper&#8217; custom elements or  these components in your code. Could yo please explain how to use case 3 and case 4 with in example.</p>
]]></content:encoded>
		
			</item>
	</channel>
</rss>

<!--
Performance optimized by W3 Total Cache. Learn more: https://www.boldgrid.com/w3-total-cache/

Object Caching 0/1320 objects using Memcache
Page Caching using Disk: Enhanced 
Minified using Disk
Database Caching using Disk (Request-wide modification query)

Served from: christianlydemann.com @ 2026-02-23 01:37:51 by W3 Total Cache
-->