opengovsg / pdf2md

A PDF to Markdown converter
https://www.npmjs.com/package/@opendocsg/pdf2md
MIT License
195 stars 39 forks source link

Add TypeScript Declaration File. #78

Closed zhzLuke96 closed 8 months ago

zhzLuke96 commented 8 months ago

Problem

Add TypeScript type definitions for the pdf2md library to improve integration with TypeScript projects.

Solution

Wrote a types/pdf2md.d.ts type definition file with declarations for the pdf2md interface.

Features:

Improvements:

inimeseke commented 6 months ago

The TS definition file is not included in the NPM package at the moment.

I think that this change should be made in package.json

"files": [ "/lib", "/test", "/types" ],

inimeseke commented 6 months ago

I would do it, but I don't know how to use Github properly

zhzLuke96 commented 6 months ago

The TS definition file is not included in the NPM package at the moment.

I think that this change should be made in package.json

"files": [ "/lib", "/test", "/types" ],

Oops, this my bad... This change requires the package owner to repackage and republish, but before that, a new PR is needed to modify the package.json. If @inimeseke you'd like to fix it, you can: fork it => fix it => submit a PR. Thank you.