I’m making a Chrome extension and I’m trying to add functionality of adding my own youtube video suggestion panels to youtube pages, so clickable elements on youtube which take user to a videopage.
Behaviour should be exactly same as if clicking on the videos on youtube: because it’s an SPA, the page is not refreshed, but videopage replaces a part of the DOM.
First thing I tried was doing
window.location.href = "https://www.youtube.com/watch?v=m-ioG4KEVyc"
, but this is too naive and the whole page gets reloaded(duh).
How would one go about making youtube load the video page from a link without reloading the whole page when I don’t have access to the underlying angular app?