Skip to content
This repository has been archived by the owner on Aug 29, 2023. It is now read-only.

Types issue #38

Closed
ShayBox opened this issue Jul 5, 2020 · 6 comments · May be fixed by #52
Closed

Types issue #38

ShayBox opened this issue Jul 5, 2020 · 6 comments · May be fixed by #52

Comments

@ShayBox
Copy link

ShayBox commented Jul 5, 2020

image

EDIT:
Also unrelated but login being a promise is very inconvenient
image

@adumont
Copy link
Owner

adumont commented Jul 5, 2020 via email

@ShayBox
Copy link
Author

ShayBox commented Jul 5, 2020

This is the project i'm using it in, though I have a typings/tplink-cloud-api/index.d.ts file to let me compile, so that would need removed https://github.com/shaybox/api, just delete all the route files except for energy.ts and the import/use lines in index.ts, optionally remove the now unused deps

@adumont
Copy link
Owner

adumont commented Jul 5, 2020 via email

@ShayBox
Copy link
Author

ShayBox commented Jul 5, 2020

The problem is the package is written in typescript and transpiled to javascript without any type definitions, usually in this case you would either have typescript emit a definition file and provide that with the library on npm, or only transpile it to javascript for npm and set it up so typescript users can install it via github to get the typescript source, I wouldn't know how to set either of those up, here's the first article I found on the first method (generating type definitions)

@adumont
Copy link
Owner

adumont commented Jul 6, 2020 via email

aciccarello added a commit to aciccarello/tplink-cloud-api that referenced this issue Aug 26, 2021
@ShayBox
Copy link
Author

ShayBox commented Oct 16, 2021

I just noticed this issue is still open, it was fixed

@ShayBox ShayBox closed this as completed Oct 16, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants