Having a larger hood than the cooktop or range is a good practice so that the vapour from cooking are contained easier.
Many gas cooktops/ranges have a measurement requiring a minimum clearance to combustible material.
The manufacturer of cooking equipment will have this clearance specified in their installation manual. Or at least they should.
Here we have always used 18" from the side of cooktop.... but
I got caught on one home where the distance required was 24" and we had to rework the kitchen at yours truly expense.

That was back in 2000 and since then we check every cooktop's spec's.
With gas cooking when the flame is on and one uses a large pot, the heat rises on the outer edge of the pot therefor exposing a larger area to the heat.
Upper wall cabinets or light valances are subjected to this heat.
Can become an issue if not careful.