Skip to content

Commit

Permalink
Export TextareaAutosizeProps type (#265)
Browse files Browse the repository at this point in the history
* fix: export Props type

* Rename Props to TextareaAutosizeProps

Co-authored-by: Mateusz Burzyński <mateuszburzynski@gmail.com>
  • Loading branch information
SimenB and Andarist authored May 24, 2020
1 parent f8803ef commit 1d1bba2
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
5 changes: 5 additions & 0 deletions .changeset/spotty-hornets-wait.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'react-textarea-autosize': patch
---

Exported `TextareaAutosizeProps` type for convenience.
4 changes: 2 additions & 2 deletions src/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ type Style = Omit<
height?: number;
};

type Props = JSX.IntrinsicElements['textarea'] & {
export type TextareaAutosizeProps = JSX.IntrinsicElements['textarea'] & {
maxRows?: number;
minRows?: number;
onHeightChange?: (height: number) => void;
Expand All @@ -21,7 +21,7 @@ type Props = JSX.IntrinsicElements['textarea'] & {

const TextareaAutosize: React.ForwardRefRenderFunction<
HTMLTextAreaElement,
Props
TextareaAutosizeProps
> = (
{
cacheMeasurements,
Expand Down

0 comments on commit 1d1bba2

Please sign in to comment.