Yes, but only with the iPhone 6s and iPhone 6s Plus or later.
The iPhone 6s was upgraded to a 5 megapixel FaceTime HD camera in front. Unlike older iPhones, the iPhone 6s is capable of capturing selfie panoramas using the front camera.In addition to panoramas, the FaceTime HD camera supports slow motion video recording, and features a front-facing flash. The flash is generated by the Retina display.
Those with older iPhones can only capture panoramic photos with the back camera.