-
Notifications
You must be signed in to change notification settings - Fork 28
feat: moving node imports over to using the node: prefix #729
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
Conversation
| @@ -1,7 +1,7 @@ | |||
| import type { TSGeneratorOptions } from '../../../src/codegen/languages/typescript'; | |||
|
|
|||
| import { promises as fs } from 'fs'; | |||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
no idea why i loaded fs/promises like this. the things you find in small refactors...
| } | ||
|
|
||
| return fetchHar(har as any, { | ||
| return fetchHar(har as Har, { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The HAR coming out of @readme/oas-to-har is a HAR but not a full one so we need to cast this.
| const responseBody = await response.text(); | ||
|
|
||
| // eslint-disable-next-line @typescript-eslint/no-explicit-any | ||
| let data: any = responseBody; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
i'm guessing unknown won't fly here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
unfort not
🧰 Changes
This is mostly prework for the coming ESM support but this updates our Node module imports and requires to use the
node:protocol.I've also fixed few
anytypings in a number of spots that we missed.