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

tsc error in parse.ts #32

Closed
Eiryyy opened this issue Oct 22, 2021 · 5 comments
Closed

tsc error in parse.ts #32

Eiryyy opened this issue Oct 22, 2021 · 5 comments
Assignees
Labels

Comments

@Eiryyy
Copy link
Contributor

Eiryyy commented Oct 22, 2021

> tsc

node_modules/then-busboy/@type/parse.d.ts:4:39 - error TS2503: Cannot find namespace 'busboy'.

4 export interface ParseOptions extends busboy.BusboyConfig {
                                        ~~~~~~


Found 1 error.

I couldn't build it because of this error, so I used -skipLibCheck

@octet-stream
Copy link
Owner

Hi! Sorry for a late response. I guess I might've need to add typings for busboy to dependencies section of my package.json instead of devDependencies. My huge mistake, sorry, I was new to TS that days. I will fix that.

See: https://www.typescriptlang.org/docs/handbook/declaration-files/publishing.html#dependencies

@octet-stream octet-stream self-assigned this May 17, 2022
@octet-stream
Copy link
Owner

Okay, let's try this version in the wild: https://github.com/octet-stream/then-busboy/releases/tag/v5.1.2
I hope this will fix the issue.

@Eiryyy
Copy link
Contributor Author

Eiryyy commented May 18, 2022

@octet-stream The problem has not yet been resolved.

We need to fix this part.

then-busboy/lib/parse.ts

Lines 18 to 24 in 103ec51

// eslint-disable-next-line no-undef
export interface ParseOptions extends busboy.BusboyConfig {
/**
* Indicates whether then-busboy should cast fields values to their initial type
*/
castTypes?: boolean
}

Please check my PR #33

@octet-stream
Copy link
Owner

Yeah, it seems like it. Thanks for the PR. This should work.

@octet-stream
Copy link
Owner

@Eiryyy Eiryyy closed this as completed Dec 5, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants