How to create strongly-typed npm packages