Are there any electric car designs that use a generator engine to charge the battery?

The BMW i3 REX was exactly as the OP described: a pure electric drivetrain with a small gasoline-powered generator that kicked in to generate electricity once the battery was near empty. As I understand it, the generator was based on a BMW motorcycle engine.

This was not quite sufficient to keep the vehicle moving at highway speeds, uphill, with a full load, once the battery was empty; and when it couldn’t keep up, the car slowed to a crawl very suddenly. There were lawsuits.
See previous thread on this subject (2017).

ETA: In general, at stable highway speeds, it makes more sense energy-wise for the gasoline engine / generator to drive the wheels directly (like a Chevy Volt). But this doesn’t scale well to a larger car, and people in North America want trucks, so GM stopped offering the Volt. It’s a pity, because a concept like the Volt is exactly what’s needed to fight range anxiety.