Performance, as in the framerate, is largely unrelated to the filesize/memory use and depends on other factors such as quality of the Javascript engine, CPU speed and memory bandwidth.
Whether or not the game will run out of memory depends on the system. Mobile devices use a different memory architecture to some PCs: they share RAM between the CPU and GPU. So textures are stored in the same memory as everything else. However and old desktop machine, or a system with a low-end dedicated chip, might have 128mb of dedicated video memory (VRAM). In that case textures are stored in VRAM for better performance. Sometimes images can also be stored in RAM as well, but I'm not sure about the specifics - I think some systems don't support that. So if you have 2GB of RAM and 128mb of VRAM on your graphics card, you might only have 128mb of memory to use for images. Compare that to a tablet with 1GB of shared memory, 256mb of which is free - you can use all 256mb for images.
So in some cases a low-end desktop might have less image memory available than a mobile device, because it has limited discrete VRAM for textures. I think most modern desktop systems either share RAM with the GPU like mobiles do, or have ridiculous amounts of VRAM (2GB+). So in practice you'll probably be fine, but it's best practice to keep image memory down to ensure old systems don't run out of VRAM, and to improve performance (since any images spilling over to RAM will render slower than those in the faster VRAM).