I worked on some memory stuff for Figma, a similar app, though it's surely changed since I did.
One interesting thing about Photoshop's perspective is that it's fundamentally about "files", which is like a single bytestream that contains all the picture and which must be transferred to the browser to work on. A Figma document also can refer to images, but in a different way. The sum of the document data (like layout) and the image pixels can be extremely large, like gigabytes, but you can transfer those two things separately from server to client.
Might be off-topic but always wondered why Figma limits files to 2Gb, even the paid users. I remember once I had to present my work to stakeholders of a large company and when I opened Figma I was met with the dreaded red banner saying I exceeded the 2Gb limit and wouldn't open the file even for viewing. I was frantically posting on the forums and emailing customer support for a solution. Luckily they replied quickly and suggested I create a new file and paste the important bits on it and leave out the old stuff.
One interesting thing about Photoshop's perspective is that it's fundamentally about "files", which is like a single bytestream that contains all the picture and which must be transferred to the browser to work on. A Figma document also can refer to images, but in a different way. The sum of the document data (like layout) and the image pixels can be extremely large, like gigabytes, but you can transfer those two things separately from server to client.