Snippets working when page is reloaded