Head Lights Turn off after 10min

Yep I had a similar problem, going down the road at night and my lights would go out. I then would turn the switch off and then back on the my lights would come back on so I change my dimmer switch, end of problem...