Update TypeScript to be consistent across different packages. PR Close #41620
Updates the repo to TypeScript 4.2 and tslib 2.1.0. PR Close #41158