President Trump on Thursday signed an executive order that paves the way for a deal brokered by his administration to keep TikTok operating in the U.S.