<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[how and where should I use the hide&show function offered by MM?]]></title><description><![CDATA[<p dir="auto">I tried to hide all other modules except the current module, but it seems does not work. I put my codes to hide other modules inside the start function of the current module.</p>
<pre><code>
Module.register("MMM-hideOtherModules",{
    defaults:{},
    start:function(){
         setTimeout("shutOtherModule",5000);
         function shutOtherModule(){
             MM.getModules().exceptModule(this).enumerate(function(module){
                 module.hide();
             })
         }
    },
//not important functions
}
</code></pre>
<p dir="auto">Could anyone help me with a sample module to hide other modules? Are there any place to learn about the inner structure of inter-modules communication except the doc?</p>
]]></description><link>https://forum.magicmirror.builders/topic/9321/how-and-where-should-i-use-the-hide-show-function-offered-by-mm</link><generator>RSS for Node</generator><lastBuildDate>Mon, 20 Jul 2026 13:37:48 GMT</lastBuildDate><atom:link href="https://forum.magicmirror.builders/topic/9321.rss" rel="self" type="application/rss+xml"/><pubDate>Wed, 26 Dec 2018 07:15:39 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to how and where should I use the hide&show function offered by MM? on Wed, 26 Dec 2018 13:37:47 GMT]]></title><description><![CDATA[<p dir="auto">turn on the developers console with Ctrl-Shift=i, or npm start dev, then you can use the console and sources tabs to see errors in the module.js and also put stops on code and look at the variables</p>
<p dir="auto">as u found, the MM variable is only available in the module.js</p>
]]></description><link>https://forum.magicmirror.builders/post/48580</link><guid isPermaLink="true">https://forum.magicmirror.builders/post/48580</guid><dc:creator><![CDATA[sdetweil]]></dc:creator><pubDate>Wed, 26 Dec 2018 13:37:47 GMT</pubDate></item><item><title><![CDATA[Reply to how and where should I use the hide&show function offered by MM? on Wed, 26 Dec 2018 16:32:06 GMT]]></title><description><![CDATA[<p dir="auto">I use MMM-ModuleScheduler to show or hide modules. It works very simple out of the box.</p>
]]></description><link>https://forum.magicmirror.builders/post/48582</link><guid isPermaLink="true">https://forum.magicmirror.builders/post/48582</guid><dc:creator><![CDATA[Arjan]]></dc:creator><pubDate>Wed, 26 Dec 2018 16:32:06 GMT</pubDate></item><item><title><![CDATA[Reply to how and where should I use the hide&show function offered by MM? on Wed, 26 Dec 2018 13:37:47 GMT]]></title><description><![CDATA[<p dir="auto">turn on the developers console with Ctrl-Shift=i, or npm start dev, then you can use the console and sources tabs to see errors in the module.js and also put stops on code and look at the variables</p>
<p dir="auto">as u found, the MM variable is only available in the module.js</p>
]]></description><link>https://forum.magicmirror.builders/post/48580</link><guid isPermaLink="true">https://forum.magicmirror.builders/post/48580</guid><dc:creator><![CDATA[sdetweil]]></dc:creator><pubDate>Wed, 26 Dec 2018 13:37:47 GMT</pubDate></item><item><title><![CDATA[Reply to how and where should I use the hide&show function offered by MM? on Wed, 26 Dec 2018 10:12:00 GMT]]></title><description><![CDATA[<p dir="auto">Finally I deleted the node helper, it seems that MM functions does not work in node helper functions.<br />
But the setTimeout function in notificationReceived function still does not work with “DOM_OBJECT_CREATED”.</p>
]]></description><link>https://forum.magicmirror.builders/post/48571</link><guid isPermaLink="true">https://forum.magicmirror.builders/post/48571</guid><dc:creator><![CDATA[grasshopper001]]></dc:creator><pubDate>Wed, 26 Dec 2018 10:12:00 GMT</pubDate></item><item><title><![CDATA[Reply to how and where should I use the hide&show function offered by MM? on Wed, 26 Dec 2018 08:09:25 GMT]]></title><description><![CDATA[<p dir="auto">It seems that MM is not available?<br />
I tried to write shutOtherModule function in node-helper, and MagicMirror told me that</p>
<pre><code>ReferenceError: MM is not defined
</code></pre>
<p dir="auto">How could I get access to MM object? Why my MagicMirror responded me with a blank mirror when the function is called after receiving “DOM_OBJECT_CREATED” notification?</p>
]]></description><link>https://forum.magicmirror.builders/post/48563</link><guid isPermaLink="true">https://forum.magicmirror.builders/post/48563</guid><dc:creator><![CDATA[grasshopper001]]></dc:creator><pubDate>Wed, 26 Dec 2018 08:09:25 GMT</pubDate></item><item><title><![CDATA[Reply to how and where should I use the hide&show function offered by MM? on Wed, 26 Dec 2018 08:07:19 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/grasshopper001" aria-label="Profile: grasshopper001">@<bdi>grasshopper001</bdi></a> join me for a bit in discord and we will solve your problem <a href="https://forum.magicmirror.builders/topic/9298/magicmirror-hackathon-2018">https://forum.magicmirror.builders/topic/9298/magicmirror-hackathon-2018</a></p>
]]></description><link>https://forum.magicmirror.builders/post/48562</link><guid isPermaLink="true">https://forum.magicmirror.builders/post/48562</guid><dc:creator><![CDATA[strawberry 3.141]]></dc:creator><pubDate>Wed, 26 Dec 2018 08:07:19 GMT</pubDate></item><item><title><![CDATA[Reply to how and where should I use the hide&show function offered by MM? on Wed, 26 Dec 2018 07:29:18 GMT]]></title><description><![CDATA[<p dir="auto">codes&amp;question updated</p>
<pre><code>setTimeout(shutOtherModule(),10000);
                function shutOtherModule(){
                     MM.getModules().exceptModule(this).enumerate(function(module){
                     module.hide();
                     })
                 }
</code></pre>
<p dir="auto">question:<br />
When I put the above codes in start function, the module never hides other modules.<br />
When I put the above codes in notificationReceived function and let MagicMirror do the codes after receiving “DOM_OBJECT_CREATED” notification, It seems that the module shuts down all modules including itself, leaving me with a blank mirror.</p>
]]></description><link>https://forum.magicmirror.builders/post/48560</link><guid isPermaLink="true">https://forum.magicmirror.builders/post/48560</guid><dc:creator><![CDATA[grasshopper001]]></dc:creator><pubDate>Wed, 26 Dec 2018 07:29:18 GMT</pubDate></item></channel></rss>