After wrestling countless hours with a problem (as you do) I came to the conclusion that ShaderMaterial is broken in 3.0. More accurately, I can't get texture lookups to work in vertex shader. But they do work in Babylon 2.5
Add this line in any vertex shader and it wont compile:
vec4 test = texture2D(textureSampler, uv);