Skip to content

Commit

Permalink
Added ts-expect-error
Browse files Browse the repository at this point in the history
  • Loading branch information
mattpocock committed Jun 22, 2023
1 parent 9cf88fc commit 0788d79
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import { Equal, Expect } from "../helpers/type-utils";

const buttonProps = {
type: "button",
// This should be erroring! Why isn't it?
// @ts-expect-error
illegalProperty: "I AM ILLEGAL",
};

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,9 @@ import { Equal, Expect } from "../helpers/type-utils";
const buttonProps = {
type: "button",
// This should be erroring! Why isn't it?
// @ts-expect-error
illegalProperty: "I AM ILLEGAL",
} satisfies ComponentProps<"button">;
};

<>
<button {...buttonProps}>Click Me!</button>
Expand Down

0 comments on commit 0788d79

Please sign in to comment.