Skip to content

Commit

Permalink
Apply suggestions from code review
Browse files Browse the repository at this point in the history
Co-authored-by: Ryan Christian <[email protected]>
  • Loading branch information
JoviDeCroock and rschristian authored Dec 12, 2024
1 parent ad707a8 commit 8f49af0
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions content/en/guide/v10/typescript.md
Original file line number Diff line number Diff line change
Expand Up @@ -214,13 +214,11 @@ Class components include children by default, typed as `ComponentChildren`.
## Inheriting HTML properties

When we write components like `<Input />` that wrap the HTML `<input>`, most of the time we'd want to inherit
the props that can be used on the native HTML input element. To do this we can do the following
the props that can be used on the native HTML input element. To do this we can do the following:

```tsx
import { JSX } from 'preact';

type HTMLInputProperties = ;

interface InputProperties extends JSX.InputHTMLAttributes<HTMLInputElement> {
mySpecialProp: any
}
Expand Down

0 comments on commit 8f49af0

Please sign in to comment.