Skip to content

Commit 060fe9b

Browse files
chillitomagilgur5
authored andcommitted
fix imports and make extra props optional
1 parent f2536de commit 060fe9b

File tree

2 files changed

+6
-3
lines changed

2 files changed

+6
-3
lines changed

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
"version": "1.0.1",
44
"description": "A signature pad implementation in React",
55
"main": "build/index.js",
6-
"types": "src/index.d.ts",
6+
"types": "src/index.d.ts",
77
"scripts": {
88
"test": "webpack && npm pack",
99
"start": "webpack-dev-server -d --inline --hot",

src/index.d.ts

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
1+
2+
import * as React from 'react';
3+
14
// signature_pad's props
25
// (taken from https://github.com/szimek/signature_pad/blob/e2af461bca7ceb7cc5afb8349930908ca19f2f56/src/signature_pad.ts#L23)
36
export interface IOptions {
@@ -15,8 +18,8 @@ export interface IOptions {
1518

1619
// props specific to the React wrapper
1720
export interface SignatureCanvasProps extends IOptions {
18-
canvasProps: any;
19-
clearOnResize: boolean;
21+
canvasProps?: any;
22+
clearOnResize?: boolean;
2023
}
2124

2225
export default class SignatureCanvas extends React.Component<SignatureCanvasProps> {}

0 commit comments

Comments
 (0)