TCMiranda / joi-extract-type

Provides native type extraction from Joi schemas for Typescript
MIT License
151 stars 27 forks source link

fix: add ts-nocheck to `index.ts` for declaration file to be emitted. #46

Closed jasonaibrahim closed 2 years ago

jasonaibrahim commented 2 years ago

@TCMiranda I bypassed typechecking in order to get tsc to produce the declaration file for index.ts. I then installed the library into a project that uses sideway/joi with the following:

npm install --save-dev github:jasonaibrahim/joi-extract-type#ca8e8deadcfdac7db294fa641fd3064faec29cfa

I get the intellisense features and the types are accurately produced based on the Joi schema

However, there are still a number of issues in index.spec.ts - mainly TS2315: Type 'extractType' is not generic.

I am hoping you can offer some insight here, as we are now getting outside my wheelhouse 😄