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

feat(*): first draft to type the Api reader #8

Open
wants to merge 3 commits into
base: feat-typescript
Choose a base branch
from

Conversation

TheMoums
Copy link

No description provided.

@TheMoums TheMoums requested a review from OlivierCuyp January 28, 2022 11:23
Headers as nHeaders,
BodyInit as nBodyInit,
RequestInit as nRequestInit
} from 'node-fetch';
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I now, this is only a lint change but we should import types here instead of the objects.

@@ -130,7 +119,7 @@ export class IsoApiReader {
}

mergeHeaders(baseHeaders: IsoHeaders, newHeaders: IsoHeaders): IsoHeaders {
const finalHeaders = new this.Headers(baseHeaders);
const finalHeaders = new this.Headers(baseHeaders as nHeaders);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Here you force the type to be nHeaders, but how do you know what got ?

@ftorrado ftorrado force-pushed the feat-typescript-mirror branch 2 times, most recently from a62cf7c to 6afe755 Compare March 28, 2022 11:39
@ftorrado ftorrado force-pushed the feat-typescript-mirror branch from 6afe755 to 533ff32 Compare March 28, 2022 11:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants