It was studying variable stars in the Small Magellanic Cloud that lead to Leavitt's law. She discovered that the time of the variability (period) and the brightness (luminosity) were related. Since all the stars were at about the same distance from Earth, this relationship must be something intrinsic to the stars.

Image credit: ESO/VISTA VMC