Store the favorites in the database, rather than in browser. It should be connected to the user rather than just localstorage in a browser.