I think it is possible for a subset of websites (because you can’t preload all links by default, some trigger an action such as a logout), that’s an idea I had in mind.
I pasted the js code into a userscript.
Works great! I hope I won't have too many accidents with it.
I remember using 10 years ago a similar Windows program that preloaded all links.