I think they did it on the server but I am perplexed on how they were able to do it. I have not found any tutorial online that satisfy this kind of requirement. Might be threejs but what are the steps in doing this. Thank you
Redbubble use ImageMagick composites of multiple layers (base, artwork & overlay) for simple flat mockups.
For more complex mockups like above as well as mugs, shower curtains, Throw Pillows etc, they use a custom Service created with Blender to map the artwork on to a 3D model, then use the same ImageMagick process as above.