fix: Changes relative import paths in usePreferredCameraDevice.ts
(#2661)
Update import paths in usePreferredCameraDevice The import paths for CameraDevice and useCameraDevices in the usePreferredCameraDevice file were updated. They now correctly reference 'react-native-vision-camera' instead of the non-existent relative path. This ensures correct and efficient module importation, enhancing code readability and maintainability.
This commit is contained in:
parent
97941a919f
commit
ebe04b246c
@ -1,7 +1,6 @@
|
|||||||
import { useMMKVString } from 'react-native-mmkv'
|
import { useMMKVString } from 'react-native-mmkv'
|
||||||
import { CameraDevice } from '../../../src/CameraDevice'
|
|
||||||
import { useCallback, useMemo } from 'react'
|
import { useCallback, useMemo } from 'react'
|
||||||
import { useCameraDevices } from '../../../src/hooks/useCameraDevices'
|
import { CameraDevice, useCameraDevices } from 'react-native-vision-camera'
|
||||||
|
|
||||||
export function usePreferredCameraDevice(): [CameraDevice | undefined, (device: CameraDevice) => void] {
|
export function usePreferredCameraDevice(): [CameraDevice | undefined, (device: CameraDevice) => void] {
|
||||||
const [preferredDeviceId, setPreferredDeviceId] = useMMKVString('camera.preferredDeviceId')
|
const [preferredDeviceId, setPreferredDeviceId] = useMMKVString('camera.preferredDeviceId')
|
||||||
|
Loading…
Reference in New Issue
Block a user