NASA has formally approved plans — a year ahead of schedule — for an infrared space telescope launching around 2024 to record unique wide-angle views of the cosmos, seeking answers to questions about mysterious dark energy and searching for habitable worlds around other stars.