File tree Expand file tree Collapse file tree 4 files changed +9
-7
lines changed
src/components/VideoCapture Expand file tree Collapse file tree 4 files changed +9
-7
lines changed Original file line number Diff line number Diff line change 2727 "styles" : [
2828 " src/styles.css"
2929 ],
30- "scripts" : []
30+ "scripts" : [],
31+ "baseHref" : " ./"
3132 },
3233 "configurations" : {
3334 "production" : {
Original file line number Diff line number Diff line change 11{
2- "name" : " dbrjs-react-sample" ,
2+ "name" : " dbrjs-react-hook- sample" ,
33 "version" : " 0.1.0" ,
44 "private" : true ,
5+ "homepage" : " ./" ,
56 "dependencies" : {
67 "@testing-library/jest-dom" : " ^5.17.0" ,
78 "@testing-library/react" : " ^13.4.0" ,
Original file line number Diff line number Diff line change @@ -86,11 +86,10 @@ function VideoCapture() {
8686 alert ( errMsg ) ;
8787 }
8888 }
89+ // Resolve pInit promise once initialization is complete.
90+ resolveInit ! ( ) ;
8991 } ) ( ) ;
9092
91- // Resolve pInit promise once initialization is complete.
92- resolveInit ! ( ) ;
93-
9493 // componentWillUnmount. dispose cvRouter when it's no longer needed
9594 return async ( ) => {
9695 isDestroyed = true ;
@@ -99,13 +98,13 @@ function VideoCapture() {
9998 await pInit ;
10099 cvRouter ?. dispose ( ) ;
101100 cameraEnhancer ?. dispose ( ) ;
102- } catch ( _ ) { }
101+ } catch ( _ ) { }
103102 } ;
104103 } , [ ] ) ;
105104
106105 return (
107106 < div >
108- < div ref = { cameraViewContainer } style = { { width : "100%" , height : "70vh" } } > </ div >
107+ < div ref = { cameraViewContainer } style = { { width : "100%" , height : "70vh" } } > </ div >
109108 < br />
110109 Results:
111110 < div ref = { resultsContainer } className = "results" > </ div >
Original file line number Diff line number Diff line change 22 "name" : " dbrjs-react-sample" ,
33 "version" : " 0.1.0" ,
44 "private" : true ,
5+ "homepage" : " ./" ,
56 "dependencies" : {
67 "@testing-library/jest-dom" : " ^5.17.0" ,
78 "@testing-library/react" : " ^13.4.0" ,
You can’t perform that action at this time.
0 commit comments