Skip to content

[expect-type] Constructor parameters ignored in .toEqualTypeOf #244

@mmkal

Description

@mmkal

Repro:

import { expectTypeOf } from 'expect-type'

class Foo {
  constructor(input: string) {}
}

class Bar {
  constructor(input: number) {}
}

expectTypeOf<Foo>().not.toEqualTypeOf<Bar>() // fails!

playground

Originally posted by @mmkal in trpc/trpc#955 (comment)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions