Yes, the inverter can be used while travelling down the road and the engine alternator will charge the batteries.
Now, in the words of Paul Harvey, for the rest of the story.
In my coach not all circuits are run through the inverter. For instance neither the coach AC nor the passengers 120VAC power receptacle are run through the inverter. If we want to use the house AC or have power to charge the wife's tablet while travelling I have to run the generator. I find myself using the generator more than the inverter.
Hopefully this answers your question.
US Army (Ret)
2020 Entegra Accolade 37TS
2019 Jeep Grand Cherokee Trailhawk (Toad)
FMCA - F432054