The world's first all-electric passenger aircraft has successfully taken to the sky.