laser diodes generally have a feedback circuit to prevent burn-out if designed properly. if your heats up a lot, it probably was not designed properly.
I was planning to make a laser alarm with KY-008 Laser Module and arduino
<CUT>The 91 Ohm resistor is apparent in the photo above on the outfacing side of the laser behind the brass ferrule. There's also a 10k Ohm resistor mounted on the PCB that goes between the middle pin and the "S" pin.<CUT>