form</code> route (or vice-versa) will tear down the anonymous component and recreate the DOM from scratch. If the Layout component had <a href="lifecycle-methods.html">lifecycle methods</a> defined, the <code>oninit</code> and <code>oncreate</code> hooks would fire on every route change. Depending on the application, this may or may not be desirable.</p>
<p>If you would prefer to have the Layout component be diffed and maintained intact rather than recreated from scratch, you should instead use a RouteReso