So as far as I understand, the basic idea of a linear regulator is to use a series-pass element along with an opamp with negative feedback to stabilize the output. This is what I usually see as an example:
simulate this circuit – Schematic created using CircuitLab
Now, to use a MOSFET in place of the BJT, can I just do a direct replacement like this:
Or should the gate of the MOSFET be driven by another BJT like below?
Or does it not make any difference? Is one more stable than the other?
Also I remember reading somewhere on the internet that in order for the opamp to regulate correctly, a small current should flow out of the output through the negative feedback loop, but a MOSFET gate doesn't allow any current in, which is also confusing.