How to make panel or page invisible after certain period of time

I have a question regarding visibility of panel/page. I found how to make panel/page visible with toggle from the document. My question is how to make it invisible again or go to another page after certain period of time without clicking a button. I have tried it with javascript, Timer, but it just goes to the another page after time that I have set.
Is there any way to do it in fusetools?

Hi 0427hjy

I think you need yo use WhileTrue to accomplish what you need

	var Observable = require('FuseJS/Observable');

	var showPanel = Observable(true);
	// hide after 3 seconds
	setTimeout( function(){
	    showPanel.value = false;
	},3000 );

	module.exports = {
		showPanel : showPanel

<WhileTrue Value="{showPanel}">
	<!-- what you need to hide here -->


I hope my answer helps you. Best Wishes