Spectroscopic observations show that all planetary nebulae are expanding , and so the idea arose that planetary nebulae were caused by a star 's outer layers being thrown into space at the end of its life .

This meant that they were caused by a star 's outer layers being thrown into space at the end of its life .
