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

Whitepsace matching is too sensitive for functions #213

Closed
danvk opened this issue Nov 27, 2023 · 0 comments · Fixed by #214
Closed

Whitepsace matching is too sensitive for functions #213

danvk opened this issue Nov 27, 2023 · 0 comments · Fixed by #214

Comments

@danvk
Copy link
Owner

danvk commented Nov 27, 2023

This type assertion fails:

async function fetchANumber(...args: Parameters<typeof fetch>): Promise<number> { ... }

fetchANumber
// ^? function fetchANumber(
//      input: RequestInfo | URL, init?: RequestInit | undefined
//    ): Promise<number>

with this error:

  Expected: function fetchANumber( input: RequestInfo | URL, init?: RequestInit | undefined ): Promise<number>
    Actual: function fetchANumber(input: RequestInfo | URL, init?: RequestInit | undefined): Promise<number>

Putting the whole expected type on one line with the spaces still fails the test in the same way.

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 a pull request may close this issue.

1 participant