Use ts lib.d.ts

Close #11, #16