I read somewhere that the generator should be in ‘inverter’ to run electronics. True?
I think there is a confusion of terms.
A generator is a rotary mechanical/electrical device and it is either a AC or DC current source.
To take an DC power source (like a battery) and make AC current requires an electrical device called an inverter (inverts the wave form positive to negative and so on using power transistors).
Generators produce rather "dirty" power due to speed fluctuations and so forth. It used to be to get the cleanest power you'd have a DC generator charging a battery stack. The DC power would then be chopped by an inverter to clean AC.
The electronics that accompany modern high quality generators use things like digital governors make the direct output suitable for home electronics.