Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

errorMessages in props is not optional #63

Open
mst-mkt opened this issue Sep 4, 2024 · 0 comments · May be fixed by #64
Open

errorMessages in props is not optional #63

mst-mkt opened this issue Sep 4, 2024 · 0 comments · May be fixed by #64

Comments

@mst-mkt
Copy link

mst-mkt commented Sep 4, 2024

The errorMessages in the props of the Camera component is not optional.

Therefore, the following error occurs if props is omitted as follows.

 <Camera ref={cameraRef} />
Property 'errorMessages' is missing in type '{ ref: RefObject<CameraType>; aspectRatio: number; }' but required in type 'CameraProps'.ts

To resolve the error, it should be stated as such.

 <Camera ref={cameraRef} errorMessages={{}} />

The README is marked as optional, as shown below, so this is considered to be an implementation error.
https://github.com/purple-technology/react-camera-pro/blob/master/README.md?plain=1#L74

@mst-mkt mst-mkt linked a pull request Sep 4, 2024 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant