Shader to RGBTurns the data (casting in programming speak) into RGB colors. Without this we cannot change the colors using a color ramp,
Color Ramp noderemaps the grey values to the color you want,
Mix shadernode is a grey value. It determines the mixing factor of shader 1 and shader 2. White color shows
Shader 2, black color shows
difference node(a mix node) compares the original texture to
color 2(the color we want to remove when texture do not have alpha channel, black if it has alpha).
less than node(a math node) refines the edges of the mask using the threshold value.
diffuse BSDF nodecan be exchanged to
Emission shaderfor shadeless texture or a more elaborate setup.
Alpha Clip, Alpha Blend or Alpha Hatch. Which of these Blend mode you choose will depend on your use case.