Introduce TypeScript
Refactor references