Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Are there plans to support Typescript #14

Open
dkrutsko opened this issue Apr 2, 2023 · 2 comments
Open

Are there plans to support Typescript #14

dkrutsko opened this issue Apr 2, 2023 · 2 comments

Comments

@dkrutsko
Copy link

dkrutsko commented Apr 2, 2023

Have you considered adding Typescript types for this library to better support Typescript projects using this library?

@spencermountain
Copy link
Owner

oh hey David, fellow Torontonian -
yeah sure - I can put a types file in, or I'd welcome a pr
cheers

@dkrutsko
Copy link
Author

dkrutsko commented Apr 3, 2023

Awesome stuff, I'm still not too sure how the types are implemented on the library level, I'm guessing it's just a file? In the other PR I posted my version of the unpack function. I think for your current API it should be as simple as implementing two functions right? Something along the lines of:

pack (s: string[] | Record<string, string>): string
unpack (s: string): Record<string, string>

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants