I have multiple textures, one of which gets bound to TEXTURE0 before drawing.
In my fragment shaders, I have a single sampler2D uniform such as:
uniform sampler2D diffuse;
I used to call uniform1f([uniform location], 0) every frame, every shader to explicitly set the uniform to read texture unit zero but, after removing those calls, my app still works on the Linux, Windows, and Mac systems I tested. This is not conclusive evidence that not setting the uniform is safe, hence the question: Is it safe to assume that unset sampler2D uniforms will read texture unit 0?
The motivation for removing the uniform1f calls was to reduce draw calls, which are especially expensive when working in webassembly because there is an additional overhead to call javascript.
I didn't see any mention of a default in the spec, aside from a user settable default that is only supported in opengl 4 (not WebGL 2). I should note that there were no errors in console after the change.