The one you’ll use most frequently is , which runs after the component is first rendered to the DOM. We briefly encountered it when we needed to interact with a <canvas> element after it had been rendered.

    If the onMount callback returns a function, that function will be called when the component is destroyed.